This commit is contained in:
parent
88adfa691e
commit
0d20b2f019
@ -1,11 +1,15 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
|
echo $DRONE_TAG
|
||||||
|
echo $GOOS
|
||||||
|
echo $GOARCH
|
||||||
|
|
||||||
if [[ ! -z $DRONE_TAG && ! -z $GOOS && ! -z $GOARCH ]]
|
if [[ ! -z $DRONE_TAG && ! -z $GOOS && ! -z $GOARCH ]]
|
||||||
then
|
then
|
||||||
mkdir dist
|
mkdir dist
|
||||||
go build -o dist/qrz-${DRONE_TAG}-${GOOS}-${GOARCH} -mod=vendor -ldflags='-s -w' cmd/qrz/*.go
|
go build -o dist/qrz-${DRONE_TAG}-${GOOS}-${GOARCH} -mod=vendor -ldflags='-s -w' cmd/qrz/*.go
|
||||||
cd dist
|
cd dist
|
||||||
tar -czvf qrz-${DRONE_TAG}-${GOOS}-${GOARCH}.tar.gz
|
tar -czvf qrz-${DRONE_TAG}-${GOOS}-${GOARCH}.tar.gz qrz-${DRONE_TAG}-${GOOS}-${GOARCH}
|
||||||
else
|
else
|
||||||
echo "Required variables not set"
|
echo "Required variables not set"
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user