Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

brotli --test --verbose should show a message #729

Closed
stokito opened this issue Oct 29, 2018 · 4 comments
Closed

brotli --test --verbose should show a message #729

stokito opened this issue Oct 29, 2018 · 4 comments

Comments

@stokito
Copy link

stokito commented Oct 29, 2018

When running a integrity test brotli shows nothing and t his is correct according to unix philosophy.
But when I asked the brotli to be verbose it still didn't show anything:

$ brotli -vt goodarchive.br
$ brotli -vt corrupt.br
corrupt input [corrupt.br]

What do I expect is the same behavior as for gzip, xz and many other compressors:

$ gzip -vt goodarchive.gz
goodarchive.gz:	 OK
$ gzip -vt corrupt.br
gzip: corrupt.gz: not in gzip format

As you can see in verbose mode test shows a file name and status OK.

Could you make brotli to work similar with other compressors?

@eustas
Copy link
Collaborator

eustas commented Oct 29, 2018

Surely. Will implement that soon (when get some free cycles =)

@stokito
Copy link
Author

stokito commented Oct 30, 2018

@eustas thank you. Also please note that gzip, uncompress, bzip2, lzip, lzma, xz, lzop compressors usually prints an output to stderr instead of stdout but rar and 7zip prints to stdout.
So I'm not sure what is a correct behavior but please implement according to some standard de-facto i.e. stderr.

@eustas
Copy link
Collaborator

eustas commented Oct 30, 2018

Currently CLI prints something to stdout only for --help and --version, i.e. when user directly requested some output.
For "verbose" + "test" options stderr seems to be the only right destination, to make it consistent with other "verbose" outputs.

@eustas
Copy link
Collaborator

eustas commented Dec 15, 2021

I think it is fixed now:

 ~$ brotli -tv gato.html.br 
Decompressed [gato.html.br]: 698 B -> 4.395 KiB

@eustas eustas closed this as completed Dec 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants