uv-virtualenvwrapper
A lightweight replacement for virtualenvwrapper when using uv.
Why uv-virtualenvwrapper?
uv is a fantastic, high-performance tool for managing Python packages and virtual environments. However, it currently lacks a built-in way to easily manage multiple named environments in a centralized location (see feature request).
uv-virtualenvwrapper fills this gap by providing a simple bash/zsh script with tab completion, mirroring the core functionality of virtualenvwrapper specifically for use with uv. It allows for quick creation, activation, removal, and listing of named Python virtual environments. Virtual environments are stored centrally in ~/.virtualenvs by default and can be activated with workon <name>. Pre/postactivate hooks from virtualenvwrapper are not supported.
Installation
Method 1: Direct Download
- Download the script: Download uv-virtualenvwrapper.sh.
- Add to shell config:
Add
source /path/to/uv-virtualenvwrapper.sh
to your shell configuration file (~/.bashrcor~/.zshrc).
Method 2: Install with uv
- Install uv-virtualenvwrapper:
uv tool install uv-virtualenvwrapper
- Add to shell config:
Add
source $(which uv-virtualenvwrapper.sh)
to your shell configuration file (~/.bashrcor~/.zshrc).
Usage
| Command | Description |
|---|---|
mkvirtualenv [options] <name> |
Creates a new virtual environment named <name> and activates it. All options are passed to uv venv --seed. |
workon [name] |
Activates the virtual environment named <name>. If no name is given, lists available environments. |
rmvirtualenv <name> |
Removes the virtual environment named <name>. |
lsvirtualenv |
Lists all available virtual environments. |
deactivate |
Deactivates the current virtual environment. (Standard venv command) |
Virtual environments are stored in WORKON_HOME (default: ~/.virtualenvs).
Example:
$ mkvirtualenv myenv
$ uv pip install requests
$ deactivate
[...]
$ workon myenv
$ uv pip list
License
Links
Metadata
Release files for uv-virtualenvwrapper 1.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| uv_virtualenvwrapper-1.0.1.tar.gz | 3.7 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| uv_virtualenvwrapper-1.0.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 8.0 kB
Release files / uv_virtualenvwrapper-1.0.1.tar.gz
| Download URL | uv_virtualenvwrapper-1.0.1.tar.gz |
|---|---|
| Size | 3.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e497611123e05cb8bab34e62f4b4c274e290202dce3c358a4a10dc496cb91b71
|
|
BLAKE2b-256 checksum How to use checksums |
20d178fb7c21cdad248a1664d133091b30863450f00542670bb2c3c96399dc57
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.1
|
Release files / uv_virtualenvwrapper-1.0.1-py3-none-any.whl
| Download URL | uv_virtualenvwrapper-1.0.1-py3-none-any.whl |
|---|---|
| Size | 4.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
df956b8846389d35ccee0564532f91660e1544a002471465b3735627c9d87523
|
|
BLAKE2b-256 checksum How to use checksums |
d4f7b5927f86e2c18a096ae1792ea3bc478eabf63a7c3fa8313ea4eb55066803
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.1
|