fix sh error.
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
This commit is contained in:
parent
ae65bbf8e1
commit
97b381b748
|
@ -1,10 +1,12 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
for GOOS in darwin linux windows; do
|
|
||||||
for GOARCH in 386 amd64; do
|
OS="darwin linux windows"
|
||||||
|
ARCH="amd64"
|
||||||
|
|
||||||
|
for GOOS in $OS; do
|
||||||
|
for GOARCH in $ARCH; do
|
||||||
EXE="gopush"
|
EXE="gopush"
|
||||||
if [ $GOOS == "windows" ]; then
|
(test "$GOOS" = "windows") && EXE="gopush.exe"
|
||||||
EXE="gopush.exe"
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo "Build: ${GOOS}, Arch: ${GOARCH}, EXE: ${EXE}"
|
echo "Build: ${GOOS}, Arch: ${GOARCH}, EXE: ${EXE}"
|
||||||
GOOS=$GOOS GOARCH=$GOARCH go build -ldflags="-w" -o bin/$GOOS/$GOARCH/${EXE} gopush.go;
|
GOOS=$GOOS GOARCH=$GOARCH go build -ldflags="-w" -o bin/$GOOS/$GOARCH/${EXE} gopush.go;
|
||||||
|
|
Loading…
Reference in New Issue