Skip to content

Commit 4d3c2b2

Browse files
committed
added github action for releases triggered on push to tags starting with 'v'
1 parent bc3dbbd commit 4d3c2b2

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

.github/workflows/github.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Github Release
2+
3+
on: [push]
4+
5+
permissions:
6+
contents: read
7+
8+
jobs:
9+
release:
10+
runs-on: ubuntu-latest
11+
if: startsWith(github.ref, 'refs/tags/v')
12+
13+
permissions:
14+
contents: write
15+
16+
steps:
17+
- name: Checkout
18+
uses: actions/checkout@v3
19+
20+
- name: Check if pre-release
21+
id: prerelease
22+
run: |
23+
echo "prerelease=$(if [[ "${{ github.ref }}" == *"rc"* ]]; then echo "true"; else echo "false"; fi)" >> "$GITHUB_OUTPUT"
24+
25+
- name: Release
26+
uses: softprops/action-gh-release@v1
27+
with:
28+
prerelease: ${{ steps.prerelease.outputs.prerelease }}
29+
generate_release_notes: true

0 commit comments

Comments
 (0)