diff --git a/pipeline/build/build.go b/pipeline/build/build.go index 74ac70a72..b1c50622e 100644 --- a/pipeline/build/build.go +++ b/pipeline/build/build.go @@ -91,7 +91,7 @@ func run(target buildTarget, command, env []string) error { "GOARM="+target.goarm, ) if out, err := cmd.CombinedOutput(); err != nil { - return fmt.Errorf("build failed: %s/%s %s\n%v", target.goos, target.goarch, target.goarm, string(out)) + return fmt.Errorf("build failed: %s\n%v", target.PrettyString(), string(out)) } return nil } diff --git a/pipeline/build/target.go b/pipeline/build/target.go index b2e0f2efe..f1c739e9c 100644 --- a/pipeline/build/target.go +++ b/pipeline/build/target.go @@ -19,14 +19,18 @@ func (t buildTarget) String() string { return fmt.Sprintf("%v%v%v", t.goos, t.goarch, t.goarm) } +func (t buildTarget) PrettyString() string { + return fmt.Sprintf("%v/%v%v", t.goos, t.goarch, t.goarm) +} + func buildTargets(ctx *context.Context) (targets []buildTarget) { for _, target := range allBuildTargets(ctx) { if !valid(target) { - log.Println("Skipped invalid build target:", target) + log.Println("Skipped invalid build target:", target.PrettyString()) continue } if ignored(ctx, target) { - log.Println("Skipped ignored build target:", target) + log.Println("Skipped ignored build target:", target.PrettyString()) continue } targets = append(targets, target)