mirror of
https://github.com/Horizontal42/summarum.git
synced 2026-11-10 19:11:58 +03:00
strip version-bump commits and PR numbers from release notes
This commit is contained in:
parent
0fb63e9150
commit
826e041593
1 changed files with 8 additions and 2 deletions
10
.github/workflows/release.yml
vendored
10
.github/workflows/release.yml
vendored
|
|
@ -92,14 +92,20 @@ jobs:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
run: |
|
run: |
|
||||||
prev=$(git tag --sort=-v:refname | grep -v "^${{ github.ref_name }}$" | head -1)
|
prev=$(git tag --sort=-v:refname | grep -v "^${{ github.ref_name }}$" | head -1)
|
||||||
|
# release-checklist version bumps (bump version to X / bump cargo
|
||||||
|
# version to X / update tauri.conf version to X / sync Cargo.lock
|
||||||
|
# or package-lock.json with X) are internal bookkeeping, not
|
||||||
|
# user-facing changes — never worth a changelog line.
|
||||||
|
noise='^- (bump( cargo)? version to|update tauri\.conf version to|sync (Cargo\.lock|package-lock\.json) with) [0-9]+\.[0-9]+\.[0-9]+$'
|
||||||
|
filter() { grep -vE "$noise" | sed -E 's/ \(#[0-9]+\)$//'; }
|
||||||
{
|
{
|
||||||
echo "## What's new"
|
echo "## What's new"
|
||||||
if [ -n "$prev" ]; then
|
if [ -n "$prev" ]; then
|
||||||
git log "$prev..${{ github.ref_name }}" --pretty=format:"- %s" --no-merges | grep -v "^- bump version"
|
git log "$prev..${{ github.ref_name }}" --pretty=format:"- %s" --no-merges | filter
|
||||||
echo ""
|
echo ""
|
||||||
echo "**Full Changelog**: https://github.com/${{ github.repository }}/compare/$prev...${{ github.ref_name }}"
|
echo "**Full Changelog**: https://github.com/${{ github.repository }}/compare/$prev...${{ github.ref_name }}"
|
||||||
else
|
else
|
||||||
git log "${{ github.ref_name }}" --pretty=format:"- %s" --no-merges | grep -v "^- bump version"
|
git log "${{ github.ref_name }}" --pretty=format:"- %s" --no-merges | filter
|
||||||
fi
|
fi
|
||||||
} > notes.md
|
} > notes.md
|
||||||
gh release edit "${{ github.ref_name }}" --notes-file notes.md --draft=false
|
gh release edit "${{ github.ref_name }}" --notes-file notes.md --draft=false
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue