Scan directories to find Python virtual environments
Project description
envscan — CLI to discover Python environments
envscan is a small, open-source command-line tool that scans a directory tree and reports the Python environments it finds — venv, virtualenv, uv, and conda, plus pipenv/poetry and pyenv markers — in a clean, aligned table.
Install
pip install envscan
For local development (editable install from source):
python -m pip install -e .
Quick start
- Scan the current directory:
envscan
- Scan a specific directory and print JSON:
envscan --path ./project --format json
- Show each environment's Python version:
envscan --python-version
- List installed packages in each environment:
envscan --packages
- Search for a specific library across every environment found (optionally pinned to an exact version):
envscan --search "monai"
envscan --search "monai==1.2.7"
Command reference
--path PATH: Path to scan (default.)--depth INT: Max recursion depth (default3)--format {text,json}: Output format (defaulttext)--include-hidden: Include hidden files and directories (.venvis always scanned regardless of this flag, since it's the standard name across venv/virtualenv/uv)--follow-symlinks: Follow symbolic links--python-version: Show each environment's Python version (runs its interpreter; failures are shown inline in the table, no--verboseneeded)--packages: List installed packages in each environment (runs pip/conda/uv)--search QUERY: Only show environments with a given library installed, e.g.--search "monai"or--search "monai==1.2.7"(exact-version matching only —>=,<=, etc. are not supported)--json-file PATH: Write JSON output to the given file--verbose: Verbose output (extra diagnostic logging)
Notes
- By default envscan uses conservative file-marker heuristics (e.g., presence of
pyvenv.cfg,conda-meta,Pipfile,.python-version) and does not execute any discovered interpreters. Use--python-versionor--packagesto opt into running an environment's own interpreter/pip/conda/uv.
Contributing
Contributions welcome — open a PR with tests.
License
MIT
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file envscan-0.2.1.tar.gz.
File metadata
- Download URL: envscan-0.2.1.tar.gz
- Upload date:
- Size: 17.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ea0b79211d678c71659e57cdb6645d82746c4d7b16412b5156c2a6580299bef5
|
|
| MD5 |
1e43fc6dc79219191b094aa00f489696
|
|
| BLAKE2b-256 |
aa241a4e34bad7970e225c8b3ce99b9488ec6431ca9579e82c2f28a5b8fb23b6
|
File details
Details for the file envscan-0.2.1-py3-none-any.whl.
File metadata
- Download URL: envscan-0.2.1-py3-none-any.whl
- Upload date:
- Size: 14.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cf98c1003b0853379efec716d524ea4a38dbb98be324f1f1246986083a89af96
|
|
| MD5 |
3bbb31584040d75e6c0470cf41d5bb5b
|
|
| BLAKE2b-256 |
bb54c959690ebde85b40256add9851e4884d1091519a6006e0cd134c6ecfebcb
|