修改 编译脚本

master
dengsgo 2018-09-30 09:43:14 +08:00
parent cae4bf355e
commit a5fb3aea36
6 changed files with 12 additions and 5 deletions

View File

@ -17,8 +17,8 @@ go version >=1.10,推荐 1.11
### 下载二进制文件
Github: [正式版 v1.1](https://github.com/dengsgo/fileboy/releases)
Gitee: [正式版 v1.1](https://gitee.com/dengsgo/fileboy/releases)
Github: [正式版 v1.2](https://github.com/dengsgo/fileboy/releases)
Gitee: [正式版 v1.2](https://gitee.com/dengsgo/fileboy/releases)
下载已经编译好的对应平台二进制文件,重命名为`fileboy`, 加入系统 Path 中即可。

View File

@ -3,6 +3,6 @@ echo build start...
SET CGO_ENABLED=0
SET GOOS=darwin
SET GOARCH=amd64
go build -ldflags "-s -w"
go build -ldflags "-s -w" -o fileboy-darwin-amd64.bin
echo build success
pause

View File

@ -3,6 +3,6 @@ echo build start...
SET CGO_ENABLED=0
SET GOOS=linux
SET GOARCH=amd64
go build -ldflags "-s -w"
go build -ldflags "-s -w" -o fileboy-linux-amd64.bin
echo build success
pause

View File

@ -3,6 +3,6 @@ echo build start...
SET CGO_ENABLED=0
SET GOOS=windows
SET GOARCH=amd64
go build -ldflags "-s -w"
go build -ldflags "-s -w" -o fileboy-windows-amd64.exe
echo build success
pause

View File

@ -12,6 +12,7 @@ import (
"os"
"os/exec"
"path"
"strconv"
"sync"
"time"
)
@ -230,6 +231,10 @@ func parseArgs() {
parseConfig()
run(new(changeFile))
return
case "version":
fallthrough
case "v":
fmt.Println("[VERSION] Release: v1.2 filegirl: " + strconv.Itoa(Version))
default:
fmt.Print(helpStr)
}

2
raw.go
View File

@ -60,6 +60,8 @@ Usage of fileboy:
fileboy, filegirl.yaml
exec
command
version
`
var englishSay = []string{