Skip to content

Commit

Permalink
Create binaries for darwin-amd64, darwin-arm64, linux-arm64 (#60)
Browse files Browse the repository at this point in the history
Fix #44

Co-authored-by: João Reis <[email protected]>
  • Loading branch information
weideng1 and joao-r-reis authored Oct 19, 2022
1 parent 9d6e62a commit 62a8407
Showing 1 changed file with 34 additions and 1 deletion.
35 changes: 34 additions & 1 deletion .github/workflows/release-binary.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,37 @@ jobs:
export GOARCH=amd64
go build -o zdm-proxy-${{ github.ref_name }}.exe ./proxy
zip -vr zdm-proxy-windows-amd64-${{ github.ref_name }}.zip zdm-proxy-${{ github.ref_name }}.exe LICENSE
- name: Build Darwin/amd64 binary
run: |
export GO111MODULE=on
export CGO_ENABLED=0
export GOOS=darwin
export GOARCH=amd64
go build -o zdm-proxy-${{ github.ref_name }} ./proxy
tar cvfz zdm-proxy-darwin-amd64-${{ github.ref_name }}.tgz zdm-proxy-${{ github.ref_name }} LICENSE
- name: Build Darwin/arm64 binary
run: |
export GO111MODULE=on
export CGO_ENABLED=0
export GOOS=darwin
export GOARCH=arm64
go build -o zdm-proxy-${{ github.ref_name }} ./proxy
tar cvfz zdm-proxy-darwin-arm64-${{ github.ref_name }}.tgz zdm-proxy-${{ github.ref_name }} LICENSE
- name: Build Linux/arm64 binary
run: |
export GO111MODULE=on
export CGO_ENABLED=0
export GOOS=linux
export GOARCH=arm64
go build -o zdm-proxy-${{ github.ref_name }} ./proxy
tar cvfz zdm-proxy-linux-arm64-${{ github.ref_name }}.tgz zdm-proxy-${{ github.ref_name }} LICENSE
- name: Generate Checksums
run: |
sha256sum zdm-proxy-linux-amd64-${{ github.ref_name }}.tgz | cut -d ' ' -f 1 > zdm-proxy-linux-amd64-${{ github.ref_name }}-sha256.txt
sha256sum zdm-proxy-windows-amd64-${{ github.ref_name }}.zip | cut -d ' ' -f 1 > zdm-proxy-windows-amd64-${{ github.ref_name }}-sha256.txt
sha256sum zdm-proxy-darwin-amd64-${{ github.ref_name }}.tgz | cut -d ' ' -f 1 > zdm-proxy-darwin-amd64-${{ github.ref_name }}-sha256.txt
sha256sum zdm-proxy-darwin-arm64-${{ github.ref_name }}.tgz | cut -d ' ' -f 1 > zdm-proxy-darwin-arm64-${{ github.ref_name }}-sha256.txt
sha256sum zdm-proxy-linux-arm64-${{ github.ref_name }}.tgz | cut -d ' ' -f 1 > zdm-proxy-linux-arm64-${{ github.ref_name }}-sha256.txt
- name: Create Release
uses: softprops/action-gh-release@v1
with:
Expand All @@ -45,4 +72,10 @@ jobs:
zdm-proxy-linux-amd64-${{ github.ref_name }}.tgz
zdm-proxy-linux-amd64-${{ github.ref_name }}-sha256.txt
zdm-proxy-windows-amd64-${{ github.ref_name }}.zip
zdm-proxy-windows-amd64-${{ github.ref_name }}-sha256.txt
zdm-proxy-windows-amd64-${{ github.ref_name }}-sha256.txt
zdm-proxy-darwin-amd64-${{ github.ref_name }}.tgz
zdm-proxy-darwin-amd64-${{ github.ref_name }}-sha256.txt
zdm-proxy-darwin-arm64-${{ github.ref_name }}.tgz
zdm-proxy-darwin-arm64-${{ github.ref_name }}-sha256.txt
zdm-proxy-linux-arm64-${{ github.ref_name }}.tgz
zdm-proxy-linux-arm64-${{ github.ref_name }}-sha256.txt

0 comments on commit 62a8407

Please sign in to comment.