Skip to content

Commit

Permalink
Merge pull request #6 from thecreed/add-release-action
Browse files Browse the repository at this point in the history
add gh-action build and release action
  • Loading branch information
neel-bp authored Jun 9, 2023
2 parents 3510dbb + c2118b0 commit 0f964f7
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
on:
release:

name: Build Release
jobs:
release-linux-amd64:
name: release linux/amd64
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Build
uses: hashicorp/actions-go-build@main
with:
go_version: 1.18
os: linux
arch: amd64
product_name: gthooks
product_version: ${{github.ref_name}}
debug: true
instructions: |
go build -o "$BIN_PATH" -trimpath -buildvcs=false
- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
name:
files: out/gthooks*

0 comments on commit 0f964f7

Please sign in to comment.