Extract and create archive files (zip, rar, 7z, tar, gz).
This skill triggers when user wants to extract, create, or list archive files.
StepActionWhy1DETECTIdentify archive format (zip/tar/gz/rar/7z)2CHECKVerify tools available for format3EXECUTEExtract, create, or list4VERIFYConfirm success, report errors
bash
# Optional (for rar/7z support)
brew install unar p7zip
text
├── Extract archive
│ └── Use: archive.py extract file.zip -o ./output
│
├── Create archive
│ └── Use: archive.py create output.zip ./folder
│
├── View contents
│ └── Use: archive.py list file.zip
│
└── Batch extract
└── Use: archive.py extract "*.zip"
FeatureDescriptionExtractzip, tar, tar.gz, tgz, gz, rar, 7zCreatezip, tar, tar.gzListView archive contentsBatchExtract multiple files
bash
python archive.py extract <file> [-o OUTPUT] [--password PASS]
bash
# Extract to current folder
python archive.py extract archive.zip
# Extract to specific folder
python archive.py extract archive.zip -o ./extracted
# Extract with password
python archive.py extract archive.rar --password secret
# Extract to current directory
python archive.py extract archive.7z -o ./
# Batch extract all zip files
python archive.py extract "*.zip"
bash
python archive.py create <output> <source> [--compression LEVEL]
bash
# Create zip from folder
python archive.py create myfiles.zip ./myfolder
# Create tar from folder
python archive.py create backup.tar ./folder
# Create tar.gz
python archive.py create backup.tar.gz ./folder
bash
python archive.py list <file>
bash
# List contents
python archive.py list archive.zip
# View without extracting
python archive.py list backup.tar.gz
FormatExtractCreateNoteszip✅✅Python stdlibtar✅✅Python stdlibtar.gz / tgz✅✅Python stdlibgz✅❌Python stdlibrar⚠️❌Requires unar7z⚠️❌Requires p7zip
⚠️ = requires system tools
FlagDescriptionDefault-o, --outputOutput directorycurrent dir--passwordArchive passwordnone--compression0-9 (zip only)6
python3 instead of python--password flagbrew install unar p7zipTaskCommandExtract zippython archive.py extract file.zipExtract to folderpython archive.py extract file.zip -o ./outExtract rarpython archive.py extract file.rarCreate zippython archive.py create out.zip ./folderCreate tar.gzpython archive.py create out.tar.gz ./folderList contentspython archive.py list file.zip