refactor(release): update note formatting in release previews#67
refactor(release): update note formatting in release previews#67goosewobbler merged 4 commits intomainfrom
Conversation
- Changed the formatting of note messages in the `getLabelBanner` and `formatPreviewComment` functions from `[!NOTE]` to `**Note:**` for improved clarity and consistency in release previews. - Updated unit tests to reflect the new note formatting, ensuring that the changes are accurately represented in the test outputs.
Release Preview — no release
Updated automatically by ReleaseKit |
Greptile SummaryThis PR replaces GitHub-flavored markdown alert syntax ( Key changes:
Confidence Score: 5/5Safe to merge — straightforward formatting-only change with full test coverage All changes are cosmetic string substitutions in a pure formatting function; no logic paths are added or removed, the TypeScript types are unaffected, and every modified assertion in the test suite correctly reflects the new output strings. No regressions are expected. No files require special attention
|
| Filename | Overview |
|---|---|
| packages/release/src/preview-format.ts | Replaces GitHub-flavored [!NOTE]/[!WARNING]/[!IMPORTANT] alert syntax with plain bold-text equivalents; also collapses getNoChangesMessage prefixes into the single call-site template literal |
| packages/release/test/unit/preview-format.spec.ts | Test expectations updated to match new bold-text formatting; two [!NOTE] assertions removed for label-mode bump-label tests where no note prefix is emitted in the new code |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[formatPreviewComment] --> B{result == null?}
B -- yes --> C[getLabelBanner]
B -- no --> D[getLabelBanner]
C --> E{labelContext.trigger}
D --> E
E -- commit + skip --> F["> **Warning:** This PR is marked to skip release."]
E -- commit + major --> G["> **Important:** This PR is labeled for a **major** release."]
E -- label + noBumpLabel --> H["> No release label detected. / > **Note:** Add label"]
E -- label + bumpLabel --> I["> This PR is labeled for a **bumpLabel** release."]
E -- none --> J["[]"]
B -- yes --> K{noBumpLabel?}
K -- no --> L["> **Note:** No releasable changes detected. getNoChangesMessage"]
K -- yes --> M[skip note push]
Reviews (4): Last reviewed commit: "refactor(release): simplify no changes m..." | Re-trigger Greptile
…n release previews - Updated the formatting of warning and important messages in the `getLabelBanner` function to enhance clarity, changing from `[!WARNING]` and `[!IMPORTANT]` to `**Warning:**` and `**Important:**`. - Adjusted related unit tests to verify the new message formats, ensuring consistency in the output of release previews.
…g in release previews - Consolidated warning and important messages in the `getLabelBanner` function for improved readability by removing unnecessary line breaks. - Updated unit tests to reflect the changes in message formatting, ensuring consistency in the output of release previews.
- Removed redundant phrasing from the no changes messages in the `getNoChangesMessage` function for improved clarity. - Updated the `formatPreviewComment` function to reflect the changes in message formatting, ensuring consistency in the output of release previews.
[!NOTE], [!WARNING] and [!IMPORTANT] don't display correctly in github comments.
getLabelBannerandformatPreviewCommentfunctions from[!NOTE]to**Note:**for improved clarity and consistency in release previews.