Use changelog-bot-action from GitHub Container Registry (#4419) #31
Workflow file for this run
This file contains 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
name: Prepare for a release | |
on: | |
push: | |
tags: 'release-[0-9]+.[0-9]+.[0-9]+' | |
concurrency: prepare-for-a-release | |
jobs: | |
# all tasks that need to be done before we add an X.Y.Z tag | |
# should be done as a step in the pre-tagging job. | |
# think of it like this... if when you later checkout the tag for a release, | |
# should the change be there? if yes, do it here. | |
pre-tagging: | |
name: Tasks run before tagging the release | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout main | |
uses: actions/checkout@v3 | |
with: | |
ref: "main" | |
token: ${{ secrets.RELEASE_TOKEN }} | |
- name: Update CHANGELOG.md | |
uses: ponylang/[email protected] | |
with: | |
entrypoint: update-changelog-for-release | |
env: | |
GIT_USER_NAME: "Ponylang Main Bot" | |
GIT_USER_EMAIL: "[email protected]" | |
- name: Update VERSION | |
uses: ponylang/[email protected] | |
with: | |
entrypoint: update-version-in-VERSION | |
env: | |
GIT_USER_NAME: "Ponylang Main Bot" | |
GIT_USER_EMAIL: "[email protected]" | |
# tag for release | |
# this will kick off the next stage of the release process | |
# no additional steps should be added to this job | |
tag-release: | |
name: Tag the release | |
needs: | |
- pre-tagging | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout main | |
uses: actions/checkout@v3 | |
with: | |
ref: "main" | |
token: ${{ secrets.RELEASE_TOKEN }} | |
- name: Trigger artefact creation | |
uses: ponylang/[email protected] | |
with: | |
entrypoint: trigger-artefact-creation | |
env: | |
GIT_USER_NAME: "Ponylang Main Bot" | |
GIT_USER_EMAIL: "[email protected]" | |
# all cleanup tags that should happen after tagging for release should happen | |
# in the post-tagging job. examples of things you might do: | |
# add a new unreleased section to a changelog | |
# set a version back to "snapshot" | |
# in general, post-tagging is for "going back to normal" from tasks that were | |
# done during the pre-tagging job | |
post-tagging: | |
name: Tasks run after tagging the release | |
needs: | |
- tag-release | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout main | |
uses: actions/checkout@v3 | |
with: | |
ref: "main" | |
token: ${{ secrets.RELEASE_TOKEN }} | |
- name: Add "unreleased" section to CHANGELOG.md | |
uses: ponylang/[email protected] | |
with: | |
entrypoint: add-unreleased-section-to-changelog | |
env: | |
GIT_USER_NAME: "Ponylang Main Bot" | |
GIT_USER_EMAIL: "[email protected]" |