Zip Version 11 (Python) 

Action group: File system


Description

The action creates an archive of the specified folder or file. 

Action icon


Settings of parameters

PropertyDescriptionTypeFilling exampleMandatory field
Parameters
Path to folderPath to the directory that should be compressedRobin.FolderPathC:\doc\imgNo
Path to filePath to the file to be archived.Robin.FilePath
No
Save toDirectory, where the archive should be placedRobin.FolderPathC:\doc\imgYes
Archive nameName for the archive. For BZIP2 and XZ formats, the entered information will be ignored and the archive will be created with the name of the selected file.Robin.String
Yes
Archive formatArchive format. 7z is default.Robin.String
No
If duplicatedAction to perform if an archive with the same name already exists in the folder. Default is rename - a number will be added to the name.Robin.String
No
PasswordPassword that will protect access to the created archive. Password protection is supported in 7z, zip, and rar formats. For other formats, the entered information will be ignored and the archive will be created without a password.Robin.Password
No
Archive sizeThe size of the archives into which the file or folder will be divided during archiving. If the field is not filled in, the division will not occur and only 1 archive will be created.Robin.Numeric
No
Units of measurementUnits of measurement for the «Archive size» field». The default value is Mb.Robin.String
No
Results
Archive pathFull path to the created archiveRobin.FilePath

Archive CollectionA collection containing the full paths to the created archives. The action returns this result only if the «Archive Size» field has been filled in. In this case, the result «Archive Path» will be empty.Robin.Collection

Special conditions of use

The robot will return an error if:

  • incorrect archive size is specified (<=0)

Logic of operation of the action when splitting the archive into parts:

  • The submitted archive is split into parts with the specified size. For example, the archive is 900 bytes, the size of the archives is specified as 200 bytes. 5 archives will be created (4 of 200 bytes and 1 of 100 bytes). The paths to them will be specified in the collection. 

Splitting an archive into parts supports the following formats: 7z; zip; tar.

Example of use

Task

You need to create archives based on the file path. 

Solution

Use the "Zip" action.

Implementation

  1. Move the "Zip" action to the workspace. 


  2. Set the parameters of the "Zip" action. 


  3. Click on the "Start" button in the top panel. 

Result

The program robot completed successfully.

Archives have been created in the required folder.

  • Нет меток