-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1853702
commit 8089251
Showing
6 changed files
with
453 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
changelog: | ||
categories: | ||
- title: 🎉 New Features | ||
labels: | ||
- new feature | ||
- title: ✨ Enhancements | ||
labels: | ||
- enhancement | ||
- title: 🛠 Breaking Changes | ||
labels: | ||
- breaking change | ||
- title: 🐛 Bug fixes | ||
labels: | ||
- bug | ||
- title: ⚡️ Optimisations | ||
labels: | ||
- optimisation | ||
- title: 🔭 Observability | ||
labels: | ||
- observability | ||
- title: 🔒️ Security | ||
labels: | ||
- security | ||
- title: 📝 Documentation | ||
labels: | ||
- documentation | ||
- title: 📦️ Dependencies | ||
labels: | ||
- dependencies | ||
- title: Other Changes | ||
labels: | ||
- '*' |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
name: Push Trunk Workflow | ||
on: | ||
push: | ||
branches: | ||
- "main" | ||
|
||
jobs: | ||
update-candidate: | ||
name: Update Release Candidate Notes | ||
permissions: | ||
id-token: write | ||
contents: write | ||
secrets: inherit | ||
uses: ./.github/workflows/reusable-update-release-candidate-notes.yml | ||
with: | ||
branch-with-candidate-code: main |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
name: Create Release Notes | ||
on: | ||
workflow_call: | ||
inputs: | ||
tag: | ||
required: true | ||
type: string | ||
description: Tag to be used as the latest release anchor point. Can be new or existing. | ||
workflow_dispatch: | ||
inputs: | ||
tag: | ||
required: true | ||
type: string | ||
description: Tag to be used as the latest release anchor point. Can be new or existing. | ||
|
||
jobs: | ||
create-release: | ||
name: Create Release Notes | ||
runs-on: ubuntu-latest | ||
permissions: | ||
id-token: write | ||
contents: write | ||
|
||
steps: | ||
- name: Check out code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Create Release | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
REPO: ${{ github.repository }} | ||
shell: bash | ||
run: python3 release_manager.py release ${{ inputs.tag }} | ||
|
||
clear-candidate: | ||
name: Clear Release Candidate | ||
runs-on: ubuntu-latest | ||
permissions: | ||
id-token: write | ||
contents: write | ||
|
||
steps: | ||
- name: Check out code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Clear Candidate | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
REPO: ${{ github.repository }} | ||
shell: bash | ||
run: python3 release_manager.py candidate clear |
47 changes: 47 additions & 0 deletions
47
.github/workflows/reusable-update-release-candidate-notes.yml
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
name: Update Release Candidate Notes | ||
on: | ||
workflow_call: | ||
inputs: | ||
branch-with-candidate-code: | ||
type: string | ||
workflow_dispatch: | ||
inputs: | ||
branch-with-candidate-code: | ||
description: Which branch would you like to create the release candidate from? | ||
type: string | ||
|
||
jobs: | ||
update: | ||
name: Update Candidate Release Notes | ||
runs-on: ubuntu-latest | ||
permissions: | ||
id-token: write | ||
contents: write | ||
|
||
steps: | ||
- name: Check out code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Git | ||
run: | | ||
git config --global user.email "[email protected]" | ||
git config --global user.name "GitHub Action" | ||
- name: Fetch latest commit from ${{ inputs.branch-with-candidate-code }} | ||
id: fetch-master | ||
run: | | ||
git fetch origin ${{ inputs.branch-with-candidate-code }} | ||
echo "LATEST_CANDIDATE_COMMIT=$(git rev-parse origin/${{ inputs.branch-with-candidate-code }})" >> $GITHUB_OUTPUT | ||
- name: Sync release-candidate tag | ||
shell: bash | ||
run: | | ||
git tag -fa release-candidate origin/${{ inputs.branch-with-candidate-code }} -m "Update release-candidate tag" | ||
git push origin refs/tags/release-candidate --force | ||
- name: Update release candidate | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
REPO: ${{ github.repository }} | ||
shell: bash | ||
run: python3 release_manager.py candidate update |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# Simple Release Notes | ||
|
||
A drop-in github action to generate release notes. | ||
|
||
|
||
## Setup | ||
|
||
### `changelog` via `release.yml` | ||
|
||
Create a `.github/release.yml` | ||
|
||
This will define the categorial structure of the release notes. When a pull request label matches an entry in the `release.yml`, it will be placed under the respective section. It matched against the first label to have an entry in the `categories` section. | ||
|
||
Sample `release.yml` | ||
|
||
``` yaml | ||
changelog: | ||
categories: | ||
- title: 🎉 New Features | ||
labels: | ||
- new feature | ||
- title: ✨ Enhancements | ||
labels: | ||
- enhancement | ||
- title: 🛠 Breaking Changes | ||
labels: | ||
- breaking change | ||
- title: 🐛 Bug fixes | ||
labels: | ||
- bug | ||
- title: ⚡️ Optimisations | ||
labels: | ||
- optimisation | ||
- title: 🔭 Observability | ||
labels: | ||
- observability | ||
- title: 🔒️ Security | ||
labels: | ||
- security | ||
- title: 📝 Documentation | ||
labels: | ||
- documentation | ||
- title: 📦️ Dependencies | ||
labels: | ||
- dependencies | ||
- title: Other Changes | ||
labels: | ||
- '*' | ||
``` |
Oops, something went wrong.