Display suppressed messages tip only when an error occurred.

This commit is contained in:
Dominik Picheta 2016-12-21 22:18:11 +01:00
commit 9be27cd665
3 changed files with 5 additions and 5 deletions

View file

@ -178,7 +178,7 @@ proc findNimbleFile*(dir: string; error: bool): string =
raise newException(NimbleError,
"Specified directory does not contain a .nimble file.")
else:
display("Warning", "No .nimble file found for " & dir, Warning,
display("Warning:", "No .nimble file found for " & dir, Warning,
HighPriority)
proc getInstalledPkgsMin*(libsDir: string, options: Options):

View file

@ -262,7 +262,7 @@ proc getInstalledPkgs*(libsDir: string, options: Options):
let exc = (ref ValidationError)(getCurrentException())
exc.msg = createErrorMsg(validationErrorMsg, path, exc.msg)
if exc.warnInstalled:
display("Warning", exc.msg, Warning, HighPriority)
display("Warning:", exc.msg, Warning, HighPriority)
else:
raise exc
except: