feat: 恢复发行版更新日志章节(一律 draft),接口与封面尊重草稿 - #58
Merged
Merged
Conversation
- 恢复发行版更新日志章节(中英)与 changelog-editions 条目:章节 index 带 draft: true, _category_.json 不再写 link(index 是草稿,生产构建里不存在);不恢复 05-more 的入口链接(死链会让构建失败) - changelog-json-plugin 尊重草稿:生产构建时草稿版本不进 /api/<outputFile>(仍输出合法的空列表), 草稿页面(中英)引用的封面图从站点输出中移除;开发环境行为不变 - 条目描述里写明草稿规则:发布流程写入的版本页面一律 draft: true,公开某个版本 = 把该页面的 draft 改为 false
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
变更说明 / Description
中文
plugins/changelog-editions.json条目:章节index.md带draft: true;_category_.json不再写link(index 是草稿,生产构建里不存在);不恢复05-more的入口链接(指向草稿页面的链接在生产构建里是死链,会让构建失败)。changelog-json-plugin尊重草稿:生产构建时,草稿版本不进/api/<outputFile>(该文件仍会生成,版本列表为空),草稿页面(中英)引用的封面图从站点输出中移除;开发环境行为不变。draft: true;公开某个版本 = 把该页面(中英)的draft改为false或删除该行。draft: true)在另一个 PR 中提交。English
plugins/changelog-editions.jsonentry: the sectionindex.mdcarriesdraft: true;_category_.jsonno longer setslink(the index is a draft and does not exist in production builds); the entry links from05-moreare not restored (links to draft pages are broken links in production builds and fail the build).changelog-json-pluginnow honors drafts: in production builds draft versions are left out of/api/<outputFile>(the file is still generated, with an empty version list) and the cover images referenced by draft pages (zh + en) are removed from the site output; development behavior is unchanged.draft: true; publishing a version means settingdrafttofalse(or deleting the line) on that page (zh + en).draft: true) is a separate PR.测试方式 / Test Plan
NODE_ENV):草稿/非草稿混合、全部为草稿、封面路径穿越(输出目录之外的文件不会被删)均符合预期 / Verified the plugin locally on a temporary site directory in both production and development modes: mixed and all-draft cases and cover-path traversal (files outside the output directory are never deleted) behave as expected.api/changelog.json完全一致,OEM 的版本列表为空 / On the real tree in production mode: the 170 desirecore versions are identical to the liveapi/changelog.json, and the OEM list is empty.检查清单 / Checklist