Sapcar is a compression and decompression software used by SAP companies. The patch packages and small software downloaded from SAP websites are basically extensions of car or SAR, and they can be decompressed using sapcar. The following describes how to use it:
Usage:
Create a new file:
Sapcar-C [Vir] [f Archive] [-p] [-C Directory]
[-A filename] [-T filename] [-x filename]
[-P value] [-v] file1 file2...
List the content of an archive:
Sapcar-T [vs] [f Archive] [file1 file2....]
Extract files from files:
Sapcar-X [v] [f Archive] [-r directory] [-a filename]
[-V] [file1 file2....]
Verify files:
Sapcar-d [v] [f Archive] [-V] [file1 file2....]
Append an object to an archive:
Sapcar-A [v] [f Archive] file1 [file2....]
Merge two files:
Sapcar-M [v] F "Source Target"
Check the validity of the file to be processed:
Sapcar-L [-a filename] [-x filename] [file1 file2. ..]
Other options:
-A: append an object to an archive.
-A file: Get the name contained in the file.
-Backup: Run in backup mode: Contains ACL data
(Only supported by Unicode sapcar on Windows platforms)
-C dir: Change the directory to Dir
-E: redirects the output from stdout to the sapcar_output file.
-F file: use the File file (default: Default. SAR)
-Flat: the file path is not retained when the file is extracted.
-G: Specifies the case when the file name is extracted, tested, or listed.
-H: do not modify the permission of the existing Directory during extraction
-I: Ignore inaccessible files when creating an archive
-L: check the validity of the file to be processed
-Lower: converts the file name to lowercase during extraction.
-M: merge two files
-N: print statistics
-P octalvalue: sets the permission of all files in the file to a value.
-P: use absolute path name (Exercise caution)
-R: Do not parse symbolic links/shortcuts when creating an archive
-R dir: Use dir to replace the current directory
-S: perform free space check
-T file: Rename the file contained in the file.
-V: list all processed files.
-V: Calculate or verify the checksum (obsolete, always set, out of backward compatibility)
-X file: Get names excluded from File
Example:
Use all files in the current directory to create files, including dot files:
Sapcar-CVF my. Sar.
Create an archive with all files in the current directory, excluding vertex files:
Sapcar-CVF my. sar *
Note that sapcar puts "*" and "? "As a wildcard character. The former matches all strings, while the latter
Only match any single character.
Create an archive with the full directory and directory permissions:
Sapcar-CVF my. Sar dir
Create an archive with all the files in the directory, excluding the directory itself:
Sapcar-CVF my. Sar DIR /*
If the directory dir does not exist when sapcar-xvf my. Sar is used for extraction, you need permission 755 to create the directory.
Use only files in the directory to create an archive
Sapcar-CVF my. Sar-C dir.
Or better
(CD dir; sapcar-CVF ../My. Sar .)
Merge two files:
Sapcar-MVF "source-archive.sar target-archive.sar"
Append an object to an archive:
Sapcar-aVF archive. Sar file1 file2 file3
Extract/verify files:
If you try to extract a file from a document that does not meet the sapcar second specification, sapcar assumes that it is
Files in the old format, and the corresponding extraction routine is automatically started. If the file still cannot be processed, it will
Stop execution. Note that extracting old files only works under the naming options that can be processed by the old car application.
Use absolute path name:
If you use an absolute path name to create an archive, the file will be extracted to these path names! Sapcar does not look like UNIX
The tool tar truncates the start slash (/).
Specify a file list for extraction/verification/List:
Use double quotation marks to include this list.
If all file paths do not contain spaces, the list must be separated by spaces or commas. For example:
Sapcar-xvf "archive1.sar archive2.sar"
If at least one file path contains spaces, the list must be separated by commas. For example:
Sapcar-xvf "archive with blank. Sar, archive. Sar, archive2.sar"
Specify a separate file path containing spaces:
Enclose the file name with double quotation marks.
Create: unless a comma is a part of a path, it cannot contain a comma at the end. For example:
Sapcar-CVF "archive with blank. Sar "*
Extract/verify/list: A comma must be appended. For example:
Sapcar-xvf "archive with blank. Sar ,"
To extract/verify/list multiple files with wildcards, the file name parameters must be marked with double quotation marks for Transmission
Evaluate the wildcards of the command line shell. In this way, such
Sapcar-xvf K *. SAR
Only one file is extracted,
While
Sapcar-xvf "K *. Sar"
This will allow sapcar to extract all files in the matching mode "K *. Sar" in the current directory.
Use options A, T, and X:
All entries in the specified file are considered relative to the current working directory, unless the entries are absolute paths.
(In this case, the related files will be archived using the absolute path name ).
If you want to specify the paths in these files, use the slash (/) as the path delimiter.
When the old and new names in the T file contain spaces, use the pipe sign (|) to distinguish them.
If the old file name and new file name do not contain spaces, you can use spaces as the old name and new name.
Between (this means that a valid car rename file is also a valid sapcar rename File
Therefore, you can use the-T option ).
Note that pattern matching is not supported in-a,-T, and-X Files (for example, "*. cpp" will not cause
All CPP files in the current directory are processed ).
The line with # as the first non-space character is ignored by sapcar (Similarly, only the lines containing space are also
Will be ignored ).
If a path name is inserted into a specified file, the complete path with the path permission will be included in the file
.
If only DIR/filename is specified, the file will be included in the file. During extraction, if the Directory
If dir does not exist, it will be created.
Use the-C option:
All relative file names in the command line are treated as relative to the specified directory.
This is sapcar. Version: 700_rel build 780172
Compiled on Sep 19 2005, 02:00:00
Note that there are many versions of sapcar, which correspond to different operating system platforms and SAP kernel versions respectively. Pay attention to this when downloading and using sapcar.