somaz94/Compress/Decompress
Compress and decompress files in CI/CD: password-protected zip, SHA256 checksum, and 5 archive formats (zip, tar, tgz, tbz2, txz).
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Stale
- License
- None
Inputs
| name | description | required | default |
|---|---|---|---|
| command | Command to perform ("compress" or "decompress"). | yes | — |
| source | Source directory, file, or glob pattern to compress or decompress. Supports glob patterns like **/*.doc to match multiple files. | yes | — |
| dest | Destination directory for the output. | no | — |
| destfilename | Destination filename for the compressed output. | no | — |
| exclude | File(s) to exclude from compression process. | no | — |
| format | Compression format to use. Supported formats: zip, tar, tgz, tbz2, txz. | yes | — |
| includeRoot | Whether to include the root folder itself in the compressed file. | no | true |
| preserveGlobStructure | When using glob patterns, preserve the directory structure in the archive. If false, all matched files are flattened to the root level. | no | false |
| stripPrefix | Remove this prefix from file paths when preserving directory structure. Works only with glob patterns and preserveGlobStructure: true. Example: 'src/' will change 'src/app/main.py' to 'app/main.py' in the archive. | no | "" |
| fail_on_error | Whether to fail the action if compression/decompression fails. | no | true |
| compression_level | Compression level (0-9). 0 is store only, 9 is maximum compression. Applies to zip, tgz, tbz2, and txz formats. | no | "" |
| password | Password for zip encryption/decryption. Use with secrets for security. Only applies to zip format. | no | "" |
| verbose | Enable verbose logging for debugging. | no | false |
Outputs
| name | description |
|---|---|
| file_path | The path to the compressed or decompressed file. |
| checksum | SHA256 checksum of the compressed archive (compress only). |