This commit is contained in:
parent
7212f406c7
commit
92cff093bb
20
.github/workflows/发布wordpress文章.yml
vendored
20
.github/workflows/发布wordpress文章.yml
vendored
@ -46,27 +46,27 @@ jobs:
|
||||
WORDPRESS_PASSWORD: ${{ secrets.WORDPRESS_PASSWORD }}
|
||||
POST_ID: 829
|
||||
POST_STATUS: "draft"
|
||||
wp_content: ${{ env.wp_content }}
|
||||
firmware_version: ${{ env.firmware_version }}
|
||||
run: |
|
||||
FORMATTED_TIME=$(TZ='Asia/Shanghai' date "+%Y年%m月%d日")
|
||||
|
||||
# 创建 JSON 数据内容,保持 README 内容的原始格式
|
||||
# 使用 jq 生成 JSON 数据,以确保没有格式错误
|
||||
JSON_PAYLOAD=$(jq -n \
|
||||
--arg title "${FORMATTED_TIME}最新每天更新OpenWRT&LEDE x86/64 软路由精品稳定版固件下载含插件" \
|
||||
--argjson description "$wp_content" \
|
||||
--arg content "${{ env.wp_content }}" \
|
||||
--arg post_status "$POST_STATUS" \
|
||||
--arg firmware_version "$firmware_version" \
|
||||
--arg formatted_time "$FORMATTED_TIME" \
|
||||
--arg firmware_version "${{ env.firmware_version }}" \
|
||||
--arg kernel_version "6.X" \
|
||||
--arg file_size "1024MB" \
|
||||
--arg update_time "$FORMATTED_TIME" \
|
||||
'{
|
||||
title: $title,
|
||||
description: $description,
|
||||
description: $content,
|
||||
post_status: $post_status,
|
||||
custom_fields: [
|
||||
{key: "wb_dl_firmware_version", value: $firmware_version},
|
||||
{key: "wb_dl_kernel_version", value: "6.X"},
|
||||
{key: "wb_dl_file_size", value: "1024MB"},
|
||||
{key: "wb_dl_update_time", value: $formatted_time}
|
||||
{key: "wb_dl_kernel_version", value: $kernel_version},
|
||||
{key: "wb_dl_file_size", value: $file_size},
|
||||
{key: "wb_dl_update_time", value: $update_time}
|
||||
]
|
||||
}'
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user