Update portfwd.go #7
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
push: | |
tags: | |
- 'v*' | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version: '1.20' | |
- run: | | |
env GOOS=linux GOARCH=amd64 CGO_ENABLED=0 go build -ldflags="-s -w" portfwd.go | |
tar zcvf portfwd-${{ github.ref_name }}-linux-amd64.tar.gz portfwd | |
- run: | | |
env GOOS=darwin GOARCH=amd64 CGO_ENABLED=0 go build -ldflags="-s -w" portfwd.go | |
tar zcvf portfwd-${{ github.ref_name }}-macos-amd64.tar.gz portfwd | |
- run: | | |
env GOOS=darwin GOARCH=arm64 CGO_ENABLED=0 go build -ldflags="-s -w" portfwd.go | |
tar zcvf portfwd-${{ github.ref_name }}-macos-arm64.tar.gz portfwd | |
- run: | | |
env GOOS=windows GOARCH=amd64 CGO_ENABLED=0 go build -ldflags="-s -w" portfwd.go | |
zip portfwd-${{ github.ref_name }}-windows-x86_64.zip portfwd.exe | |
- uses: softprops/action-gh-release@v1 | |
with: | |
name: PortFwd ${{ github.ref_name }} | |
body: '[CHANGELOG](CHANGELOG.md)' | |
files: | | |
portfwd-${{ github.ref_name }}-linux-amd64.tar.gz | |
portfwd-${{ github.ref_name }}-macos-amd64.tar.gz | |
portfwd-${{ github.ref_name }}-macos-arm64.tar.gz | |
portfwd-${{ github.ref_name }}-windows-x86_64.zip |