Tar commands
Prepare tar commands for task-subfolder compression/extraction.
| FUNCTION | DESCRIPTION |
|---|---|
get_tar_compression_cmd |
Prepare command to compress e.g. |
get_tar_extraction_cmd |
Prepare command to extract e.g. |
Functions:¶
get_tar_compression_cmd(subfolder_path, filelist_path)
¶
Prepare command to compress e.g. /path/dir into /path/dir.tar.gz.
Note that /path/dir.tar.gz may already exist. In this case, it will
be overwritten.
| PARAMETER | DESCRIPTION |
|---|---|
|
Absolute path to the folder to compress.
TYPE:
|
|
If set, to be used in the
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
str
|
tar command |
Source code in fractal_server/runner/executors/slurm_ssh/tar_commands.py
get_tar_extraction_cmd(archive_path)
¶
Prepare command to extract e.g. /path/dir.tar.gz into /path/dir.
| PARAMETER | DESCRIPTION |
|---|---|
|
Absolute path to the tar.gz archive.
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
tuple[Path, str]
|
Target extraction folder and tar command |