Updated doc
parent
cebab1d322
commit
a7a5d7736c
|
@ -33,7 +33,8 @@ It is based on the \fBLZ77\fR family, with further FSE & huff0 entropy stages.
|
||||||
It also features a very fast decoder, with speed > 500 MB/s per core.
|
It also features a very fast decoder, with speed > 500 MB/s per core.
|
||||||
|
|
||||||
\fBzstd\fR command line is generally similar to gzip, but features the following differences :
|
\fBzstd\fR command line is generally similar to gzip, but features the following differences :
|
||||||
- Original files are preserved
|
- Source files are preserved by default
|
||||||
|
It's possible to remove them automatically by using \fB--rm\fR command
|
||||||
- By default, when compressing a single file, \fBzstd\fR displays progress notifications and result summary.
|
- By default, when compressing a single file, \fBzstd\fR displays progress notifications and result summary.
|
||||||
Use \fB-q\fR to turn them off
|
Use \fB-q\fR to turn them off
|
||||||
|
|
||||||
|
@ -57,6 +58,19 @@ It also features a very fast decoder, with speed > 500 MB/s per core.
|
||||||
.BR \-f ", " --force
|
.BR \-f ", " --force
|
||||||
overwrite output without prompting
|
overwrite output without prompting
|
||||||
.TP
|
.TP
|
||||||
|
.BR \-c ", " --stdout
|
||||||
|
force write to standard output, even if it is the console
|
||||||
|
.TP
|
||||||
|
.BR \--rm
|
||||||
|
remove source file(s) after successful compression or decompression
|
||||||
|
.TP
|
||||||
|
.BR \-k ", " --keep
|
||||||
|
keep source file(s) after successful compression or decompression.
|
||||||
|
This is the default behavior.
|
||||||
|
.TP
|
||||||
|
.BR \-r
|
||||||
|
operate recursively on directories
|
||||||
|
.TP
|
||||||
.BR \-h/\-H ", " --help
|
.BR \-h/\-H ", " --help
|
||||||
display help/long help and exit
|
display help/long help and exit
|
||||||
.TP
|
.TP
|
||||||
|
@ -69,14 +83,11 @@ It also features a very fast decoder, with speed > 500 MB/s per core.
|
||||||
.BR \-q ", " --quiet
|
.BR \-q ", " --quiet
|
||||||
suppress warnings and notifications; specify twice to suppress errors too
|
suppress warnings and notifications; specify twice to suppress errors too
|
||||||
.TP
|
.TP
|
||||||
.BR \-c ", " --stdout
|
|
||||||
force write to standard output, even if it is the console
|
|
||||||
.TP
|
|
||||||
.BR \-C ", " --check
|
.BR \-C ", " --check
|
||||||
add integrity check computed from uncompressed data
|
add integrity check computed from uncompressed data
|
||||||
.TP
|
.TP
|
||||||
.BR \-t ", " --test
|
.BR \-t ", " --test
|
||||||
Test the integrity of compressed files. This option is equivalent to \fB--decompress --stdout > /dev/null\fR.
|
Test the integrity of compressed files. This option is equivalent to \fB--decompress --stdout > /dev/null\fR.
|
||||||
No files are created or removed.
|
No files are created or removed.
|
||||||
|
|
||||||
.SH DICTIONARY
|
.SH DICTIONARY
|
||||||
|
|
|
@ -115,6 +115,7 @@ static int usage(const char* programName)
|
||||||
DISPLAY( " -D file: use `file` as Dictionary \n");
|
DISPLAY( " -D file: use `file` as Dictionary \n");
|
||||||
DISPLAY( " -o file: result stored into `file` (only if 1 input file) \n");
|
DISPLAY( " -o file: result stored into `file` (only if 1 input file) \n");
|
||||||
DISPLAY( " -f : overwrite output without prompting \n");
|
DISPLAY( " -f : overwrite output without prompting \n");
|
||||||
|
DISPLAY( "--rm : remove source file(s) after successful de/compression \n");
|
||||||
DISPLAY( " -h/-H : display help/long help and exit\n");
|
DISPLAY( " -h/-H : display help/long help and exit\n");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -132,7 +133,6 @@ static int usage_advanced(const char* programName)
|
||||||
#ifdef UTIL_HAS_CREATEFILELIST
|
#ifdef UTIL_HAS_CREATEFILELIST
|
||||||
DISPLAY( " -r : operate recursively on directories\n");
|
DISPLAY( " -r : operate recursively on directories\n");
|
||||||
#endif
|
#endif
|
||||||
DISPLAY( "--rm : remove source files after successful de/compression \n");
|
|
||||||
#ifndef ZSTD_NOCOMPRESS
|
#ifndef ZSTD_NOCOMPRESS
|
||||||
DISPLAY( "--ultra : enable ultra modes (requires more memory to decompress)\n");
|
DISPLAY( "--ultra : enable ultra modes (requires more memory to decompress)\n");
|
||||||
DISPLAY( "--no-dictID : don't write dictID into header (dictionary compression)\n");
|
DISPLAY( "--no-dictID : don't write dictID into header (dictionary compression)\n");
|
||||||
|
@ -181,7 +181,7 @@ static void waitEnter(void)
|
||||||
/*! readU32FromChar() :
|
/*! readU32FromChar() :
|
||||||
@return : unsigned integer value reach from input in `char` format
|
@return : unsigned integer value reach from input in `char` format
|
||||||
Will also modify `*stringPtr`, advancing it to position where it stopped reading.
|
Will also modify `*stringPtr`, advancing it to position where it stopped reading.
|
||||||
Note : this function can overflow if result > MAX_UNIT */
|
Note : this function can overflow if result > MAX_UINT */
|
||||||
static unsigned readU32FromChar(const char** stringPtr)
|
static unsigned readU32FromChar(const char** stringPtr)
|
||||||
{
|
{
|
||||||
unsigned result = 0;
|
unsigned result = 0;
|
||||||
|
@ -265,7 +265,7 @@ int main(int argCount, const char** argv)
|
||||||
if (!strcmp(argument, "--train")) { dictBuild=1; outFileName=g_defaultDictName; continue; }
|
if (!strcmp(argument, "--train")) { dictBuild=1; outFileName=g_defaultDictName; continue; }
|
||||||
if (!strcmp(argument, "--maxdict")) { nextArgumentIsMaxDict=1; continue; }
|
if (!strcmp(argument, "--maxdict")) { nextArgumentIsMaxDict=1; continue; }
|
||||||
if (!strcmp(argument, "--dictID")) { nextArgumentIsDictID=1; continue; }
|
if (!strcmp(argument, "--dictID")) { nextArgumentIsDictID=1; continue; }
|
||||||
if (!strcmp(argument, "--keep")) { continue; } /* does nothing, since preserving input is default; for gzip/xz compatibility */
|
if (!strcmp(argument, "--keep")) { FIO_setRemoveSrcFile(0); continue; }
|
||||||
if (!strcmp(argument, "--rm")) { FIO_setRemoveSrcFile(1); continue; }
|
if (!strcmp(argument, "--rm")) { FIO_setRemoveSrcFile(1); continue; }
|
||||||
|
|
||||||
/* '-' means stdin/stdout */
|
/* '-' means stdin/stdout */
|
||||||
|
@ -314,8 +314,8 @@ int main(int argCount, const char** argv)
|
||||||
/* Quiet mode */
|
/* Quiet mode */
|
||||||
case 'q': displayLevel--; argument++; break;
|
case 'q': displayLevel--; argument++; break;
|
||||||
|
|
||||||
/* keep source file (default anyway, so useless; for gzip/xz compatibility) */
|
/* keep source file (default); for gzip/xz compatibility */
|
||||||
case 'k': argument++; break;
|
case 'k': FIO_setRemoveSrcFile(0); argument++; break;
|
||||||
|
|
||||||
/* Checksum */
|
/* Checksum */
|
||||||
case 'C': argument++; FIO_setChecksumFlag(2); break;
|
case 'C': argument++; FIO_setChecksumFlag(2); break;
|
||||||
|
|
Loading…
Reference in New Issue