1
0
mirror of https://github.com/httpie/cli.git synced 2025-08-10 22:42:05 +02:00

Introduce a mode to suppress all warnings (#1283)

This commit is contained in:
Batuhan Taskaya
2022-03-07 15:40:35 +03:00
committed by GitHub
parent c901e70463
commit 55087a901e
6 changed files with 59 additions and 6 deletions

View File

@@ -230,9 +230,11 @@ class HTTPieArgumentParser(BaseHTTPieArgumentParser):
self.env.stdout_isatty = False
if self.args.quiet:
self.env.quiet = self.args.quiet
self.env.stderr = self.env.devnull
if not (self.args.output_file_specified and not self.args.download):
self.env.stdout = self.env.devnull
self.env.apply_warnings_filter()
def _process_auth(self):
# TODO: refactor & simplify this method.