Skip to content
This repository was archived by the owner on Mar 17, 2025. It is now read-only.

Commit 934c470

Browse files
committed
no message
1 parent ef808be commit 934c470

File tree

2 files changed

+6
-14
lines changed

2 files changed

+6
-14
lines changed

.github/workflows/generate-changeset.yml

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -179,18 +179,11 @@ jobs:
179179
# Create a temporary directory for release notes
180180
mkdir -p /tmp/release-notes
181181
182-
# Generate release notes from all changesets to a temporary file
183-
# For develop branch, include all changesets (including those from milestone branches)
184-
if [[ "${{ steps.target_branch.outputs.name }}" == "develop" ]]; then
185-
echo "Generating release notes for develop branch (including milestone branch changesets)"
186-
npm run release:notes > /tmp/release-notes/temp_notes_raw.md
187-
else
188-
# For other branches, filter by branch
189-
echo "Generating release notes for ${{ steps.target_branch.outputs.name }} branch"
190-
npm run release:notes -- --branch="${{ steps.target_branch.outputs.name }}" > /tmp/release-notes/temp_notes_raw.md
191-
fi
182+
# Generate release notes with consistent formatting
183+
echo "Generating release notes..."
184+
npm run release:notes > /tmp/release-notes/temp_notes_raw.md
192185
193-
# Remove the "Found X changesets" line and any lines starting with ">"
186+
# Process the raw notes consistently
194187
grep -v "^>" /tmp/release-notes/temp_notes_raw.md | sed -n '/^Found/!p' > /tmp/release-notes/temp_notes.md
195188
196189
# Make sure the file isn't empty

scripts/generate-release-notes.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -150,12 +150,11 @@ async function readChangesets(options = {}) {
150150
return changesets.filter(changeset => changeset.branch === branch);
151151
}
152152

153-
// Update the function that formats the changeset entries
153+
// Ensure consistent formatting for changeset entries
154154
function formatChangesetEntry(changeset) {
155-
// Remove any single quotes that might be wrapping the title
155+
// Clean up the title (remove quotes, ensure proper format)
156156
const title = changeset.title.replace(/^['"]|['"]$/g, '');
157157

158-
// Ensure we have the full title
159158
return `* **${title}** (#${changeset.pr}) - @${changeset.author}`;
160159
}
161160

0 commit comments

Comments
 (0)