From 7ab856015eeda5a29d086c519bfbe2e1b42ff72d Mon Sep 17 00:00:00 2001 From: Nicholas Wiltsie Date: Fri, 2 Aug 2024 16:27:42 -0700 Subject: [PATCH 1/3] Use workflows to manage this repo's releases --- .github/workflows/internal-finalize.yaml | 22 +++++++++++++++++ .github/workflows/internal-prepare.yaml | 31 ++++++++++++++++++++++++ 2 files changed, 53 insertions(+) create mode 100644 .github/workflows/internal-finalize.yaml create mode 100644 .github/workflows/internal-prepare.yaml diff --git a/.github/workflows/internal-finalize.yaml b/.github/workflows/internal-finalize.yaml new file mode 100644 index 0000000..43b90bd --- /dev/null +++ b/.github/workflows/internal-finalize.yaml @@ -0,0 +1,22 @@ +--- +name: Finalize release + +on: + pull_request: + branches: + - main + types: + - closed + +permissions: + actions: read + contents: write + pull-requests: write + +jobs: + finalize-release: + if: ${{ github.event.pull_request.merged == true && startsWith(github.event.pull_request.head.ref, 'automation-create-release') }} + uses: ./.github/workflows/wf-finalize-release.yaml + secrets: inherit + with: + draft: true diff --git a/.github/workflows/internal-prepare.yaml b/.github/workflows/internal-prepare.yaml new file mode 100644 index 0000000..b00d3cf --- /dev/null +++ b/.github/workflows/internal-prepare.yaml @@ -0,0 +1,31 @@ +--- +name: Prepare new release + +run-name: Open PR for new ${{ inputs.bump_type }} release + +on: + workflow_dispatch: + inputs: + bump_type: + type: choice + description: >- + Semantic version bump type + required: true + options: + - major + - minor + - patch + - prerelease + +permissions: + actions: read + contents: write + pull-requests: write + +jobs: + prepare-release: + uses: ./.github/workflows/wf-prepare-release.yaml + with: + bump_type: ${{ inputs.bump_type }} + exact_version: '' + secrets: inherit From 7e220f3124c0d2ca7a23c8595a790d2ad071576b Mon Sep 17 00:00:00 2001 From: Nicholas Wiltsie Date: Fri, 2 Aug 2024 16:28:15 -0700 Subject: [PATCH 2/3] Update .gitignore --- .gitignore | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 725cd55..460bc50 100644 --- a/.gitignore +++ b/.gitignore @@ -10,7 +10,9 @@ *.rd[as] # Python -._version.py +junit/ +.tox/ +_version.py __pycache__/ .pytest_cache/ .Python From 62af271a84aa450c388e40f92189f1a086180432 Mon Sep 17 00:00:00 2001 From: Nicholas Wiltsie Date: Fri, 2 Aug 2024 16:28:54 -0700 Subject: [PATCH 3/3] Update CHANGELOG --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index fe6acd1..d4acdcf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,3 +13,4 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm - Workflow to update CHANGELOG and open pre-release PRs - Workflow to create/draft releases after pre-release PR merge +- "Dogfood" workflows to self-manage this repository's releases