qiniu / goc

A Comprehensive Coverage Testing System for The Go Programming Language
Apache License 2.0
824 stars 118 forks source link

咨询 #299

Open sgy123456 opened 2 years ago

sgy123456 commented 2 years ago

如果构建命令是 go build -mod=vendor -v -o aaa.bin -tags tttt ./ccc/srv/main.go 用goc构建时,命令应该怎么写?

CarlJi commented 2 years ago

@sgy123456 参考下这个

# Build the current binary with cover variables injected, and set necessary build flags: -ldflags "-extldflags -static" -tags="embed kodo".
goc build --buildflags="-ldflags '-extldflags -static' -tags='embed kodo'"
sgy123456 commented 2 years ago

-mod=vendor 应该怎么加呢,这样加么? goc build --buildflags="-mod=vendor -tags 'ttt' "

Zjmainstay commented 6 days ago

升级 x/mod 到v0.11.0 以上即可。