Make sure --verbose trumps --quiet
This is so that users can have a --quiet alias in their environment and only occasionally add --verbose if they are surprised by the result.
This commit is contained in:
parent
00a302560b
commit
e5452a6b67
5
black.py
5
black.py
@ -302,7 +302,8 @@ def main(
|
||||
else:
|
||||
err(f"invalid path: {s}")
|
||||
if len(sources) == 0:
|
||||
out("No paths given. Nothing to do 😴")
|
||||
if verbose or not quiet:
|
||||
out("No paths given. Nothing to do 😴")
|
||||
ctx.exit(0)
|
||||
return
|
||||
|
||||
@ -333,7 +334,7 @@ def main(
|
||||
)
|
||||
finally:
|
||||
shutdown(loop)
|
||||
if not quiet:
|
||||
if verbose or not quiet:
|
||||
out("All done! ✨ 🍰 ✨")
|
||||
click.echo(str(report))
|
||||
ctx.exit(report.return_code)
|
||||
|
Loading…
Reference in New Issue
Block a user