Skip to main content

zipexec is a pure python alternative to zipgrep

zipexec allows you to specify any command line utiliity you would like to run against a group of .zip files. While zcat, zgrep and other utilities work well on gzip compressed files, I needed similar functionality on pkzip compressed files (with .zip extensions) and was unable to find a tool I liked.

Execute command line utilities of your choice against the contents of zip files.

Help

$ zipexec -h
usage: zipexec [-h] [-c CMD_TO_RUN] path_to_zips

positional arguments:
  path_to_zips          Where are the zips to search

optional arguments:
  -h, --help            show this help message and exit
  -c CMD_TO_RUN, --cmd_to_run CMD_TO_RUN
                        Command line to run on each zip

NOTE: Take care when specifying the names of files and commands that your local linux system does not expand the asterisks.

Example Usage

If you only pass a path to a folder containing zip files to zip exec it will prompt you for a command

$ zipexec /home/uploads/zipfiles/
What command would you like to run?: grep -R -C2 -n "search string" *

If you do specify a command with -c or --command it will execute that

Example 1: grep through the content of all the zip files:

$ zipexec -c 'grep -R -n -C2 "import os" *.py' /home/uploads/zipfiles/  

Example 2: Do a directory listing of all of the zip files that are named file*.zip

$ zipexec -c 'ls -laR' /home/uploads/zipfiles/files\*.zip   

Metadata

Release files for zipexec 1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for zipexec 1.0
File Size Uploaded Provenance
zipexec-1.0.tar.gz 2.8 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for zipexec 1.0
File Interpreter ABI Platform
zipexec-1.0-py3-none-any.whl Python 3 none any Details

Total release size: 18.0 kB

Release files / zipexec-1.0.tar.gz

Download URL zipexec-1.0.tar.gz
Size 2.8 kB
Tags Source
SHA-256 checksum
How to use checksums
ba80ada8d5f89038a6b1451066d8d2166717305cb89296a9b86c11d13d8b4c8a
BLAKE2b-256 checksum
How to use checksums
d41a3f925409c1f32d42d618d2bf4f0de7a83ee9af58a996fb80cac9704c95c7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.3.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.1.0 requests-toolbelt/0.9.1 tqdm/4.55.0 CPython/3.8.2

Release files / zipexec-1.0-py3-none-any.whl

Download URL zipexec-1.0-py3-none-any.whl
Size 15.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
bc25c82a8c7863e89bdfcf4de3138fce1cc72c9b6daa86c391508cdea628a704
BLAKE2b-256 checksum
How to use checksums
0acd2956ae801623e3ff02ea5e8d745707ce2a9b7aa01d8de1ccb90f890dba50
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.3.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.1.0 requests-toolbelt/0.9.1 tqdm/4.55.0 CPython/3.8.2

Security for zipexec 1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page