1
0
mirror of https://github.com/goreleaser/goreleaser.git synced 2025-03-17 20:47:50 +02:00

using strings.Split

This commit is contained in:
Carlos Alexandro Becker 2017-02-23 09:27:54 -03:00
parent b2fcbaeb49
commit 4bee616121
No known key found for this signature in database
GPG Key ID: E61E2F7DC14AB940

View File

@ -51,7 +51,7 @@ func build(name, goos, goarch string, ctx *context.Context) error {
}
cmd := []string{"go", "build"}
if ctx.Config.Build.Flags != "" {
cmd = append(cmd, strings.Split(ctx.Config.Build.Flags, " ")...)
cmd = append(cmd, strings.Fields(ctx.Config.Build.Flags)...)
}
cmd = append(cmd, "-ldflags="+ldflags, "-o", output, ctx.Config.Build.Main)
if err := run(goos, goarch, cmd); err != nil {