fix(release): strip Docusaurus front matter from GitHub Release notes#473
Merged
Conversation
The release job fed docs-site/docs/release-notes/<TAG>.md into `gh release create --notes-file` verbatim. GitHub renders the body as plain Markdown and does not recognise YAML front matter — worse, the closing `---` is parsed as the setext-heading underline of the metadata block above it, so the entire id:/title:/description:/sidebar_* block rendered as one giant H2 (visible on v0.10.0–v0.13.0). Strip the leading `--- ... ---` front matter with awk before publishing, emitting only the body after the second delimiter.
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.
배경
발행된 GitHub 릴리즈(v0.10.0–v0.13.0)의 본문 상단에
id:/title:/description:/sidebar_*메타데이터가 거대한 제목으로 노출되는 문제가 있었다.원인은 릴리즈 잡이
docs-site/docs/release-notes/<TAG>.md를 프론트매터째로gh release create --notes-file에 넘긴 것. GitHub은 릴리즈 본문을 일반 마크다운으로 렌더링하며 YAML 프론트매터를 인식하지 못한다. 게다가 닫는---가 위 메타데이터 블록의 setext H2 밑줄로 해석되어 블록 전체가 하나의 제목으로 렌더링됐다.변경
--notes-file에 넘기기 전에awk로 프론트매터(첫---부터 두 번째---까지)를 제거하고 그 뒤 본문만 사용하도록 수정.이미 처리한 것
gh release edit로 프론트매터를 제거해 반영 완료. 본 PR은 재발 방지(워크플로우)만 담는다.