From be9daaa646322c81d5adc058d35bb1a709122201 Mon Sep 17 00:00:00 2001 From: Kevin Stillhammer Date: Wed, 19 Jul 2023 19:40:36 +0200 Subject: [PATCH] ci: Add release-drafter (#18) --- .github/release-drafter.yml | 44 +++++++++++++++++++ .github/workflows/release-drafter.yml | 19 ++++++++ .github/workflows/update-major-minor-tags.yml | 18 ++++++++ 3 files changed, 81 insertions(+) create mode 100644 .github/release-drafter.yml create mode 100644 .github/workflows/release-drafter.yml create mode 100644 .github/workflows/update-major-minor-tags.yml diff --git a/.github/release-drafter.yml b/.github/release-drafter.yml new file mode 100644 index 0000000..8a0aaa2 --- /dev/null +++ b/.github/release-drafter.yml @@ -0,0 +1,44 @@ +name-template: 'v$RESOLVED_VERSION 🌈' +tag-template: 'v$RESOLVED_VERSION' +categories: + - title: "🚨 Breaking changes" + labels: + - "breaking-change" + - title: "✨ New features" + labels: + - "new-feature" + - title: "🐛 Bug fixes" + labels: + - "bugfix" + - title: "🚀 Enhancements" + labels: + - "enhancement" + - "refactor" + - "performance" + - title: "🧰 Maintenance" + labels: + - "maintenance" + - "ci" + - title: "📚 Documentation" + labels: + - "documentation" + - title: "⬆️ Dependency updates" + labels: + - "dependencies" +change-template: '- $TITLE @$AUTHOR (#$NUMBER)' +change-title-escapes: '\<*_&' # You can add # and @ to disable mentions, and add ` to disable code blocks. +version-resolver: + major: + labels: + - 'major' + minor: + labels: + - 'minor' + patch: + labels: + - 'patch' + default: patch +template: | + ## Changes + + $CHANGES \ No newline at end of file diff --git a/.github/workflows/release-drafter.yml b/.github/workflows/release-drafter.yml new file mode 100644 index 0000000..2f46ed4 --- /dev/null +++ b/.github/workflows/release-drafter.yml @@ -0,0 +1,19 @@ +--- +name: Release Drafter + +# yamllint disable-line rule:truthy +on: + push: + branches: + - main + workflow_dispatch: + +jobs: + update_release_draft: + name: ✏️ Draft release + runs-on: ubuntu-latest + steps: + - name: 🚀 Run Release Drafter + uses: release-drafter/release-drafter@v5.24.0 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file diff --git a/.github/workflows/update-major-minor-tags.yml b/.github/workflows/update-major-minor-tags.yml new file mode 100644 index 0000000..b815272 --- /dev/null +++ b/.github/workflows/update-major-minor-tags.yml @@ -0,0 +1,18 @@ +--- +name: Update Major Minor Tags + +# yamllint disable-line rule:truthy +on: + push: + branches-ignore: + - '**' + tags: + - 'v*.*.*' + +jobs: + update_major_minor_tags: + name: Make sure major and minor tags are up to date on a patch release + runs-on: ubuntu-latest + steps: + - name: Run Update semver + uses: haya14busa/action-update-semver@v1.2.1 \ No newline at end of file