public_Ip/build.sh
2023-12-22 14:34:59 +08:00

13 lines
270 B
Bash

:
set -x
# 静态构建Linux
go build -ldflags "-s -w"
# Windows 后台运行
GOOS=windows GOARCH=amd64 CGO_ENABLED=0 go build -ldflags="-H windowsgui" -o public_ip-Daemon.exe
# Windows Dos运行
GOOS=windows GOARCH=amd64 CGO_ENABLED=0 go build -o public_ip-Dos.exe