build.sh 561 字节
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13
rm -rf ztf
mkdir ztf
mkdir ztf/log
cp -r conf ztf/
cp -r demo ztf/

go-bindata -o=res/res.go -pkg=res res/ res/doc res/json res/template

CGO_ENABLED=0 GOOS=windows GOARCH=amd64 go build -o ztf/ztf.exe src/ztf.go
GO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o ztf/ztf-linux src/ztf.go
CGO_ENABLED=0 GOOS=darwin GOARCH=amd64 go build -o ztf/ztf-mac src/ztf.go

cd ztf
14

15
zip -r ztf-win-2.0.RC.zip ztf.exe demo conf log
16

17 18
cp -r ztf-linux ztf
zip -r ztf-linux-2.0.RC.zip ztf demo conf log
19

20 21
cp -r ztf-mac ztf
zip -r ztf-mac-2.0.RC.zip ztf demo conf log
22

23 24
rm ztf
cd ..