add linker flags

This commit is contained in:
lynn [they] 2020-02-29 13:26:25 -08:00 committed by GitHub
parent d206020179
commit 6ffee22f36
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -200,7 +200,7 @@ func checkBinarySizeActionFunc(c *cli.Context) (err error) {
)
// build example binary
err = runCmd("go", "build", "-o", builtFilePath, sourceFilePath)
err = runCmd("go", "build", "-ldflags=\"-s -w\"", "-o", builtFilePath, sourceFilePath)
if err != nil {
return err
}