Archivers' command line arguments

Far Manager

Archivers' command line arguments

The following variables can be used in external archivers' command-lines for different archive handling operations:
VariablesDescription
%%A Archive name.
%%a Archive short name.
%%W Folder for temporary files, including trailing slash symbol.
%%P Password.
%%R Current folder in the archive.
%%L List of file names (file list). It's a file containing file names to be processed by the external archiver.
%%l List of short file names.
%%F Name(s) of the file(s) to process. If all the file names don't fit in the command line then the archiver will be launched several times until all file names are processed. By default the maximum command line length is 127 symbols, but one can define it explicitly right after %%F (i.e. %%F512). The %%F variable should be used only in case the archiver doesn't support file lists.
%%f Name of a single file to process. Archiver will be launched several times until all the file names are processed. This variable should be used only in case the archiver doesn't support file lists or several file names in its command line.
%%E «exit code» Maximum allowable exit code. For example, %%E2 shows that exit codes of 0, 1 and 2 are allowed. The variable can be used at any place in the command line. If it's missing the only available exit code is 0.
%%S Place for additional command line keys defined in the second line of the "Add" dialog. When the variable is missing keys are added to the end of the command line.

Modifiers for the variables Q, S, M, N, *, W can be used for more accurate definitions of file name formats.

ModifierDescription
'Q' enclose file names with spaces in quotes;
'q' enclose all file names in quotes;
'S' use '/' instead of '\' in full paths;
'M' pass folder names to archivers as 'name\*.*';
'N' pass folder names to archivers as 'name';
'*' use '*' mask to select all files. This modifier overrides "All files Mask" parameter for any single command of the archiver;
'W' use name without path;
'P' use path without name;
'A' use ANSI encoding.

These modifiers can be used right after the %%F, %%f, %%L and %%l variables without spaces. 'P' and 'A' can also be specified after %%A and %%a. It's allowed to use several modifiers at once, for example, %%LMN or %%FQSN128. If there're no 'M' or 'N' modifiers the archiver receives both 'name' and 'name\*.*'.

If some part of the command line is enclosed in curly braces {...} it will be added to the resulting command line only in case it contains at least one not empty variable described above.

If an external archiver doesn't support some command simply leave the corresponding line empty.

See also: