forked from py-cov-action/python-coverage-comment-action
-
Notifications
You must be signed in to change notification settings - Fork 0
35 lines (27 loc) · 798 Bytes
/
manual-release.yml
File metadata and controls
35 lines (27 loc) · 798 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
name: Release Action (manual)
on: workflow_dispatch
concurrency:
group: release
jobs:
release:
name: Create new release
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout
uses: actions/checkout@v5
with:
fetch-depth: 0
fetch-tags: true
- env:
GH_TOKEN: ${{ github.token }}
run: |
set -eux
current="$(git describe --tags --abbrev=0 --match 'v*.*')"
major="$(echo $current | cut -d. -f1)"
minor="$(echo $current | cut -d. -f2)"
# Major releases will be released manually.
minor=$((minor + 1))
new_tag="${major}.${minor}"
gh release create ${new_tag} --generate-notes --notes-start-tag ${current}