diff --git a/.github/workflows/download_feishu_pages.yml b/.github/workflows/download_feishu_pages.yml index 0d7de695..b73f15d6 100644 --- a/.github/workflows/download_feishu_pages.yml +++ b/.github/workflows/download_feishu_pages.yml @@ -29,6 +29,7 @@ jobs: FEISHU_APP_SECRET: ${{ secrets.FEISHU_APP_SECRET }} FEISHU_SPACE_ID: "7288219896826494980" OUTPUT_DIR: ./feishu-pages + URL_STYLE: original uses: longbridgeapp/feishu-pages@main - uses: oven-sh/setup-bun@v1 diff --git a/bun.lockb b/bun.lockb index b582770c..135763a9 100755 Binary files a/bun.lockb and b/bun.lockb differ diff --git a/package.json b/package.json index e7ab9389..6da23550 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,7 @@ }, "dependencies": { "autocorrect-node": "^2.8.4", - "feishu-pages": "^0.5.4", + "feishu-pages": "^0.6.1", "glob": "^10.3.10", "medium-zoom": "^1.0.8", "opencc-js": "^1.0.5", diff --git a/scripts/hk2cn.js b/scripts/hk2cn.js index c37a4b16..dcc6da88 100755 --- a/scripts/hk2cn.js +++ b/scripts/hk2cn.js @@ -21,7 +21,7 @@ const convertDocsContentHK2CN = (doc) => { let newDoc = Object.assign({}, doc); newDoc.title = converter(newDoc.title); newDoc.slug = newDoc.slug.replace("zh-HK", "zh-CN"); - if (newDoc.meta) { + if (newDoc.meta?.slug) { newDoc.meta.slug = newDoc.meta.slug.replace("zh-HK", "zh-CN"); } newDoc.filename = newDoc.filename.replace("zh-HK", "zh-CN"); diff --git a/scripts/normalize_missing_docs_markdown_fields.js b/scripts/normalize_missing_docs_markdown_fields.js index 0e18cd18..e038f1fe 100755 --- a/scripts/normalize_missing_docs_markdown_fields.js +++ b/scripts/normalize_missing_docs_markdown_fields.js @@ -1,7 +1,6 @@ // 删除掉 docs.json 文件中未出现的 markdown 文件 import path from "path"; import fs from "fs"; -import { exec } from "child_process"; import { glob } from "glob"; import { removeMDFile } from "./remove_hide_file";