Skip to content

Commit bfda6dc

Browse files
committed
Improve an error message
1 parent 1bf95fc commit bfda6dc

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

v2/main.go

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -365,7 +365,11 @@ func main() {
365365
commandName = "obuild"
366366
}
367367
if err := runObuild(obuildArgs, commandName); err != nil {
368-
fmt.Fprintln(os.Stderr, err)
368+
if err.Error() == "no sources found" {
369+
fmt.Fprintln(os.Stderr, "no C or C++ sources found")
370+
} else {
371+
fmt.Fprintln(os.Stderr, err)
372+
}
369373
os.Exit(1)
370374
}
371375
os.Exit(0)

0 commit comments

Comments
 (0)