From 14630eb6a0ff2161bb616b207c8a556412ffddbd Mon Sep 17 00:00:00 2001 From: "Lars M. Rogne" Date: Wed, 24 Apr 2024 20:18:01 +0200 Subject: [PATCH] Add action --- .github/workflows/build_release.yaml | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 .github/workflows/build_release.yaml diff --git a/.github/workflows/build_release.yaml b/.github/workflows/build_release.yaml new file mode 100644 index 0000000..2332f7c --- /dev/null +++ b/.github/workflows/build_release.yaml @@ -0,0 +1,28 @@ +name: release + +on: + push: + tags: + - 'v*' + +jobs: + release: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + - name: setup go + uses: actions/setup-go@v5 + with: + go-version: '>=1.22.1' + - name: release-build-windows + run: GOOS=windows GOARCH=amd64 go build -o bin/reverse-${{ github.ref_name }}-windows-amd64.exe + - name: release-build-linux + run: GOOS=linux GOARCH=amd64 go build -o bin/reverse-${{ github.ref_name }}-linux-amd64 + - name: Release + uses: actions/release-action@main + with: + files: |- + bin/** + api_key: '${{secrets.RELEASE_TOKEN}}'