Skip to content

Commit

Permalink
build: include Darwin ARM64 build
Browse files Browse the repository at this point in the history
  • Loading branch information
maxdanilov authored and megglos committed Nov 5, 2024
1 parent 173f92a commit 3258105
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions cmd/zbctl/build.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
#!/bin/bash -xeu

OS=( linux windows darwin )
BINARY=( zbctl zbctl.exe zbctl.darwin )
OS=( linux windows darwin darwin )
ARCH=( amd64 amd64 amd64 arm64 )
BINARY=( zbctl zbctl.exe zbctl.darwin-amd64 zbctl.darwin-arm64 )

SRC_DIR=$(dirname "${BASH_SOURCE[0]}")
DIST_DIR="$SRC_DIR/dist"

Expand All @@ -13,7 +15,7 @@ rm -rf ${DIST_DIR}/*

for i in "${!OS[@]}"; do
if [ $# -eq 0 ] || [ ${OS[$i]} = $1 ]; then
CGO_ENABLED=0 GOOS="${OS[$i]}" GOARCH=amd64 go build -a -tags netgo -ldflags "-w -X github.com/camunda-community-hub/zeebe-client-go/v8/cmd/zbctl/internal/commands.Version=${VERSION} -X github.com/camunda-community-hub/zeebe-client-go/v8/cmd/zbctl/internal/commands.Commit=${COMMIT}" -o "${DIST_DIR}/${BINARY[$i]}" "${SRC_DIR}/main.go" &
CGO_ENABLED=0 GOOS="${OS[$i]}" GOARCH="${ARCH[$i]}" go build -a -tags netgo -ldflags "-w -X github.com/camunda-community-hub/zeebe-client-go/v8/cmd/zbctl/internal/commands.Version=${VERSION} -X github.com/camunda-community-hub/zeebe-client-go/v8/cmd/zbctl/internal/commands.Commit=${COMMIT}" -o "${DIST_DIR}/${BINARY[$i]}" "${SRC_DIR}/main.go" &
fi
done

Expand Down

0 comments on commit 3258105

Please sign in to comment.