-
Notifications
You must be signed in to change notification settings - Fork 0
45 lines (41 loc) · 1.18 KB
/
release.yml
File metadata and controls
45 lines (41 loc) · 1.18 KB
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
36
37
38
39
40
41
42
43
44
45
name: Release
on:
push:
branches:
- "main"
permissions:
contents: write
jobs:
release:
name: Release
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: Clone repository
uses: actions/checkout@v5
with:
fetch-depth: "0"
- name: Install Go
uses: actions/setup-go@v6
with:
go-version-file: ./go.mod
- name: Run QA
run: make qa
- name: Get next version
id: get_next_version
uses: thenativeweb/get-next-version@2.7.1
- name: Create new version
if: ${{ steps.get_next_version.outputs.hasNextVersion == 'true' }}
run: |
git tag v${{ steps.get_next_version.outputs.version }}
git push origin v${{ steps.get_next_version.outputs.version }}
- name: Build artifacts
if: ${{ steps.get_next_version.outputs.hasNextVersion == 'true' }}
run: |
make build
- name: Release new version
if: ${{ steps.get_next_version.outputs.hasNextVersion == 'true' }}
uses: ncipollo/release-action@v1
with:
artifacts: "build/*"
tag: v${{ steps.get_next_version.outputs.version }}