Skip to content

Commit

Permalink
add build script
Browse files Browse the repository at this point in the history
  • Loading branch information
hekmon committed Apr 19, 2024
1 parent 16a6821 commit 7e94a0d
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,5 @@
go.work

# Dev
/deduper
/deduper*
example/dir*
11 changes: 11 additions & 0 deletions build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/usr/bin/env bash

set -e

crosscompile () {
GOOS="$1" GOARCH="$2" go build -trimpath -ldflags="-s -w" -o 'deduper'
zip -9 "deduper_v1.0.0_${1}_${2}.zip" 'deduper'
}

echo '* Compiling for Linux'
crosscompile 'linux' 'amd64'

0 comments on commit 7e94a0d

Please sign in to comment.