lib/xmain: Print usage info in separate log

This commit is contained in:
Anmol Sethi 2022-12-01 02:47:41 -08:00
parent 80b9d1b057
commit 2df2c781e9
No known key found for this signature in database
GPG key ID: 25BC68888A99A8BA

View file

@ -66,10 +66,10 @@ func Main(run RunFunc) {
}
if msg != "" {
if usage {
msg = fmt.Sprintf("%s\n%s", msg, "Run with --help to see usage.")
}
ms.Log.Error.Print(msg)
if usage {
ms.Log.Error.Print("Run with --help to see usage.")
}
}
os.Exit(code)
}