Merge pull request #2196 from tru/dumpversion_argument
Make --version respect -q for ouptut a shorter version string
This commit is contained in:
commit
e8127b3f15
@ -238,6 +238,7 @@ the last one takes effect.
|
|||||||
display version number and exit.
|
display version number and exit.
|
||||||
Advanced : `-vV` also displays supported formats.
|
Advanced : `-vV` also displays supported formats.
|
||||||
`-vvV` also displays POSIX support.
|
`-vvV` also displays POSIX support.
|
||||||
|
`-q` will only display the version number, suitable for machine reading.
|
||||||
* `-v`, `--verbose`:
|
* `-v`, `--verbose`:
|
||||||
verbose mode
|
verbose mode
|
||||||
* `--show-default-cparams`:
|
* `--show-default-cparams`:
|
||||||
|
@ -544,6 +544,11 @@ static unsigned parseCompressionParameters(const char* stringPtr, ZSTD_compressi
|
|||||||
|
|
||||||
static void printVersion(void)
|
static void printVersion(void)
|
||||||
{
|
{
|
||||||
|
if (g_displayLevel < DISPLAY_LEVEL_DEFAULT) {
|
||||||
|
DISPLAYOUT("%s\n", ZSTD_VERSION_STRING);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
DISPLAYOUT(WELCOME_MESSAGE);
|
DISPLAYOUT(WELCOME_MESSAGE);
|
||||||
if (g_displayLevel >= 3) {
|
if (g_displayLevel >= 3) {
|
||||||
/* format support */
|
/* format support */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user