Skip to content

Automated release notes generation #119

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Sep 24, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions .github/workflows/changelog_configuration.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"categories": [
{
"title": "## 🚀 Enhancements",
"labels": ["enhancement"]
},
{
"title": "## 🔥 UI",
"labels": ["ui"]
},
{
"title": "## 🐛 Bugs",
"labels": ["bug"]
},
{
"title": "## 🧪 Tests",
"labels": ["test"]
}
],
"ignore_labels": [
"null"
],
"template": "${{CHANGELOG}}\n\n<details>\n<summary>Uncategorized</summary>\n\n${{UNCATEGORIZED}}\n</details>",
"pr_template": "- PR: #${{NUMBER}} - ${{TITLE}}",
"empty_template": "- no changes"
}

15 changes: 15 additions & 0 deletions .github/workflows/label.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
on:
pull_request:
types: [opened, labeled, unlabeled, synchronize]
name: label
jobs:
labelCheck:
name: Check that PR has a label for use in release notes
runs-on: ubuntu-latest
steps:
- name: Pull request label check
uses: mheap/github-action-required-labels@v1
with:
mode: exactly
count: 1
labels: "bug, enhancement, ui, test, exclude from release notes"
8 changes: 8 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -133,12 +133,20 @@ jobs:
run: |
aws s3 cp cmd/mccp/mccp-${{ env.TAG }}-linux-amd64 s3://weaveworks-wkp/releases/mccp-${{ env.TAG }}-linux-amd64
aws s3 cp cmd/mccp/mccp-${{ env.TAG }}-darwin-amd64 s3://weaveworks-wkp/releases/mccp-${{ env.TAG }}-darwin-amd64
- name: Build Changelog
id: github_release
uses: mikepenz/release-changelog-builder-action@v1
with:
configuration: "${{ github.workspace }}/.github/workflows/changelog_configuration.json"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
prerelease: true
fail_on_unmatched_files: true
body: ${{steps.github_release.outputs.changelog}}
files: |
cmd/mccp/mccp-${{ env.TAG }}-linux-amd64
cmd/mccp/mccp-${{ env.TAG }}-darwin-amd64