Skip to content

Commit f8cce89

Browse files
committed
ci(release): preserve changelog history and publish release commits
1 parent eb365e1 commit f8cce89

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

.github/workflows/build.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,7 @@ jobs:
126126
echo "xml_related=true" >> "${GITHUB_OUTPUT}"
127127
echo "renovate_related=true" >> "${GITHUB_OUTPUT}"
128128
echo "tooling_related=true" >> "${GITHUB_OUTPUT}"
129+
echo "workflow_related=true" >> "${GITHUB_OUTPUT}"
129130
exit 0
130131
fi
131132
fi
@@ -373,7 +374,7 @@ jobs:
373374
run: exit 1
374375

375376
publish:
376-
if: ${{ needs.detect-changes.outputs.build_related == 'true' && github.event_name == 'push' && github.ref == 'refs/heads/main' && needs.detect-changes.outputs.publish_requested == 'true' && needs.integration-tests.result == 'success' }}
377+
if: ${{ (needs.detect-changes.outputs.build_related == 'true' || needs.detect-changes.outputs.xml_related == 'true') && github.event_name == 'push' && github.ref == 'refs/heads/main' && needs.detect-changes.outputs.publish_requested == 'true' && needs.integration-tests.result == 'success' }}
377378
needs:
378379
- detect-changes
379380
- validate-template

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ jobs:
5151
run: |
5252
previous_tag="$(python3 scripts/release.py latest-aio-tag)"
5353
if [[ -n "${previous_tag}" ]]; then
54-
git-cliff --config cliff.toml --tag "${RELEASE_VERSION}" "${previous_tag}..HEAD" --output CHANGELOG.md
54+
git-cliff --config cliff.toml --tag "${RELEASE_VERSION}" "${previous_tag}..HEAD" --prepend CHANGELOG.md
5555
else
5656
git-cliff --config cliff.toml --tag "${RELEASE_VERSION}" --output CHANGELOG.md
5757
fi

0 commit comments

Comments
 (0)