Skip to content

Commit

Permalink
Add release job
Browse files Browse the repository at this point in the history
  • Loading branch information
sepisoltani committed May 1, 2024
1 parent 22e903b commit 916e9d6
Showing 1 changed file with 23 additions and 1 deletion.
24 changes: 23 additions & 1 deletion .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,26 @@ jobs:
- name: Upload coverage reports to Codecov
uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}
token: ${{ secrets.CODECOV_TOKEN }}
release:
needs: test
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/v') # This job runs only for tags starting with 'v'
steps:
- name: Check out code
uses: actions/checkout@v2

- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: '1.21'

- name: Create GitHub Release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Provided by GitHub, no need to set this secret yourself
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
draft: false
prerelease: false

0 comments on commit 916e9d6

Please sign in to comment.