Skip to content

Commit

Permalink
feat: add build script
Browse files Browse the repository at this point in the history
- eventually this could be hooked up to Github Actions but it works
for now.
  • Loading branch information
Adam Simpson committed Jun 14, 2021
1 parent 16a453b commit 839ebab
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#!/bin/sh

GIT_TAG=$(git tag | tail -1); GOOS=darwin GOARCH=arm64 go build -o arm64-macos-sb -a -ldflags="-X 'sb/cmd.AppVersion=$GIT_TAG'"

GIT_TAG=$(git tag | tail -1); GOOS=darwin GOARCH=amd64 go build -o amd64-macos-sb -a -ldflags="-X 'sb/cmd.AppVersion=$GIT_TAG'"

GIT_TAG=$(git tag | tail -1); GOOS=linux GOARCH=amd64 go build -o amd64-linux-sb -a -ldflags="-X 'sb/cmd.AppVersion=$GIT_TAG'"

zip arm64-macos-sb.zip arm64-macos-sb

zip amd64-macos-sb.zip amd64-macos-sb

zip amd64-linux-sb.zip amd64-linux-sb

rm *-sb

0 comments on commit 839ebab

Please sign in to comment.