Skip to content

Commit 064a7dc

Browse files
authored
Create release.yml
1 parent 5a978f3 commit 064a7dc

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

.github/workflows/release.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: Release
2+
3+
on:
4+
pull_request:
5+
types: [ closed ]
6+
7+
jobs:
8+
release:
9+
if: github.event.pull_request.merged == true && startsWith(github.event.pull_request.head.ref, 'release/')
10+
runs-on: ubuntu-latest
11+
timeout-minutes: 5
12+
env:
13+
GH_TOKEN: ${{ github.token }}
14+
GH_REPO: ${{ github.repository }}
15+
RELEASE_BRANCH: ${{ github.event.pull_request.head.ref }}
16+
17+
steps:
18+
- name: Create release
19+
run: |
20+
version=${RELEASE_BRANCH#release/}
21+
gh release create ${version} --title ${version} --generate-notes --discussion-category Announcements

0 commit comments

Comments
 (0)