From 453bd0ea115d37e98b1f76304dd0ac6ef8ab8eb0 Mon Sep 17 00:00:00 2001 From: Rob Allen Date: Fri, 16 Jun 2023 14:37:43 +0200 Subject: [PATCH] Add release workflow On push of version number tag, this workflow will: - Close the milestone of the same name (if it exists) - Create a GitHub release --- .github/workflows/release.yml | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..9def398 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,35 @@ +name: Release + +# On push of version number tag, this workflow will: +# - Close the milestone of the same name (if it exists) +# - Create a GitHub release + + +on: + push: + tags: + - '[0-9].*' + +permissions: + contents: write + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + + - name: Close Milestone + uses: adlerhsieh/prepare-release@0.1.2 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + REPO_OWNER: 19FT + REPO: NFNumberToWord + IGNORE_MILESTONE_NOT_FOUND: true + + - name: Release + uses: softprops/action-gh-release@v1 + with: + generate_release_notes: true + files: ${{ steps.builder.outputs.workflow_file }}