Skip to content

dh4r10/py-man

Repository files navigation

PVM — Python Version Manager

Super PyMan — Python Version Manager

Version Windows Linux Built with Rust License MIT

🇺🇸 English · 🇪🇸 Español

Install · Quick start · Commands


🇺🇸 English

Manage multiple Python versions from the terminal.
Single binary. No dependencies. No admin rights required.

Installation

Windows — via npm

npm install -g super-py-man

Then add this to your PowerShell $PROFILE:

pvm env | Out-String | Invoke-Expression

Windows — via installer

Download the installer from the latest release:

pvm-windows-x86_64-X.X.X.exe

Run the installer and follow the wizard. When done:

  • pvm.exe is placed in %LOCALAPPDATA%\pvm\
  • That path is added to the user PATH automatically
  • PowerShell profile is configured optionally

Does not require administrator privileges.
Antivirus may need to be disabled during installation.

Linux

curl -fsSL https://raw.githubusercontent.com/dh4r10/py-man/master/install.sh | bash

The script detects your architecture (x86_64 or aarch64), downloads the right binary, and configures your shell automatically (.bashrc, .zshrc, and fish). Open a new terminal and pvm is ready to use.

Quick Start

Windows

pvm install 3.13          # installs latest 3.13 patch automatically
pvm use 3.13.3
python -V
# Python 3.13.3

Linux

pvm install 3.13          # installs latest 3.13 patch automatically
pvm use 3.13.3
python --version
# Python 3.13.3

Commands

Command Description
pvm install <version> Download and install a Python version (3.13 or 3.13.3)
pvm use <version> Switch the active version
pvm list List installed versions (* marks the active one)
pvm list-remote Browse available versions grouped by minor, with interactive pagination
pvm list-remote --filter 3.12 Filter by version prefix
pvm uninstall <version> Remove an installed version
pvm default <version> Set the global default version
pvm env Print the command to add ~/.pvm/bin to your shell PATH
pvm venv <dir> Create a virtual environment pinned to the active version
pvm lang list Show available languages and the active one
pvm lang change <lang> Switch the interface language (en / es)
pvm uninstall-self Uninstall PVM from the system

Virtual Environments

PVM pins each venv to the real version path, not the active alias. Running pvm use 3.14.0 later will not affect existing venvs.

# Active version
pvm venv .venv

# Specific version without changing the active one
pvm -3.12.13 venv .venv

Windows

.venv\Scripts\activate
python -V

Linux

source .venv/bin/activate
python --version

Language

PVM supports English and Spanish. The preference is saved to ~/.pvm/lang and loaded automatically on every run.

pvm lang list              # show available languages
pvm lang change es         # switch to Spanish
pvm lang change en         # switch back to English
pvm lang -c es             # short alias

Supported Shells

pvm env detects your shell automatically. You can also specify it:

pvm env --shell bash         # export PATH="...:$PATH"
pvm env --shell zsh          # export PATH="...:$PATH"
pvm env --shell fish         # set -gx PATH "..." $PATH
pvm env --shell power-shell  # $env:PATH = "...;" + $env:PATH
pvm env --shell cmd          # @SET "PATH=...;%PATH%"

How It Works

~/.pvm/bin/ holds copies of the pvm binary renamed as shims (python, pip, etc.). When the OS runs python, it finds the shim, which resolves the active version and launches the real Python interpreter with sys.executable pointing to the exact version directory.

Windows

~/.pvm/
├── versions/3.12.13/tools/
│   ├── python.exe
│   └── Scripts/pip.exe
├── aliases/current/          ← NTFS junction → versions/3.12.13
└── bin/
    ├── python.exe            ← shim (copy of pvm.exe)
    └── pip.exe               ← shim (copy of pvm.exe)

Linux

~/.pvm/
├── versions/3.12.13/
│   ├── bin/python3
│   └── lib/
├── aliases/current           ← symlink → versions/3.12.13
└── bin/
    ├── python                ← shim (copy of pvm)
    └── pip                   ← shim (copy of pvm)

Build from Source

Requires Rust 1.70+.

Windows

git clone https://github.com/dh4r10/py-man
cd py-man
cargo build --release
# Binary at: target\release\pvm.exe

To build the Windows installer, install Inno Setup 6 and run:

iscc installer\pvm.iss
# Installer at: dist\pvm-setup-X.X.X.exe

Linux

git clone https://github.com/dh4r10/py-man
cd py-man
cargo build --release
# Binary at: target/release/pvm

Inspiration

Inspired by fnm (Fast Node Manager) — the same philosophy applied to the Python ecosystem.

🔝 Back to top


🇪🇸 Español

Gestiona múltiples versiones de Python desde la terminal.
Binario único. Sin dependencias. Sin permisos de administrador.

Instalación

Windows — Vía npm

npm install -g super-py-man

Luego añade esto a tu $PROFILE de PowerShell:

pvm env | Out-String | Invoke-Expression

Windows — Vía instalador

Descarga el instalador de la última release:

pvm-windows-x86_64-X.X.X.exe

Ejecuta el instalador y sigue el wizard. Al finalizar:

  • pvm.exe queda en %LOCALAPPDATA%\pvm\
  • Esa ruta se añade al PATH del usuario automáticamente
  • El perfil de PowerShell se configura opcionalmente

No requiere permisos de administrador.
Por ahora es necesaria la desactivación del antivirus durante la instalación.

Linux

curl -fsSL https://raw.githubusercontent.com/dh4r10/py-man/master/install.sh | bash

El script detecta tu arquitectura (x86_64 o aarch64), descarga el binario correcto y configura tu shell automáticamente (.bashrc, .zshrc y fish). Abre una terminal nueva y ya puedes usar pvm.

Inicio rápido

Windows

pvm install 3.13          # instala la última patch 3.13 automáticamente
pvm use 3.13.3
python -V
# Python 3.13.3

Linux

pvm install 3.13          # instala la última patch 3.13 automáticamente
pvm use 3.13.3
python --version
# Python 3.13.3

Comandos

Comando Descripción
pvm install <version> Descarga e instala una versión de Python (3.13 o 3.13.3)
pvm use <version> Cambia la versión activa
pvm list Lista las versiones instaladas (* marca la activa)
pvm list-remote Lista versiones disponibles agrupadas por minor, con paginación interactiva
pvm list-remote --filter 3.12 Filtra por prefijo de versión
pvm uninstall <version> Elimina una versión instalada
pvm default <version> Establece la versión global por defecto
pvm env Imprime el comando para añadir ~/.pvm/bin al PATH del shell
pvm venv <dir> Crea un entorno virtual anclado a la versión activa
pvm lang list Muestra los idiomas disponibles y el activo
pvm lang change <lang> Cambia el idioma de la interfaz (en / es)
pvm uninstall-self Desinstala PVM del sistema

Entornos virtuales

PVM ancla cada venv a la ruta real de la versión, no al alias activo. Si después haces pvm use 3.14.0, los venvs anteriores siguen apuntando a su versión original.

# Versión activa
pvm venv .venv

# Versión específica sin cambiar el use activo
pvm -3.12.13 venv .venv

Windows

.venv\Scripts\activate
python -V

Linux

source .venv/bin/activate
python --version

Idioma

PVM soporta inglés y español. La preferencia se guarda en ~/.pvm/lang y se carga automáticamente en cada ejecución.

pvm lang list              # ver idiomas disponibles
pvm lang change es         # cambiar a español
pvm lang change en         # volver a inglés
pvm lang -c es             # alias corto

Shells soportados

pvm env detecta el shell automáticamente. También puedes especificarlo:

pvm env --shell bash         # export PATH="...:$PATH"
pvm env --shell zsh          # export PATH="...:$PATH"
pvm env --shell fish         # set -gx PATH "..." $PATH
pvm env --shell power-shell  # $env:PATH = "...;" + $env:PATH
pvm env --shell cmd          # @SET "PATH=...;%PATH%"

Cómo funciona

~/.pvm/bin/ contiene copias del propio binario pvm renombradas como shims (python, pip, etc.). Cuando el sistema operativo ejecuta python, encuentra el shim, que resuelve la versión activa y lanza el Python real con sys.executable apuntando al directorio exacto de la versión.

Windows

~/.pvm/
├── versions/3.12.13/tools/
│   ├── python.exe
│   └── Scripts/pip.exe
├── aliases/current/          ← junction NTFS → versions/3.12.13
└── bin/
    ├── python.exe            ← shim (copia de pvm.exe)
    └── pip.exe               ← shim (copia de pvm.exe)

Linux

~/.pvm/
├── versions/3.12.13/
│   ├── bin/python3
│   └── lib/
├── aliases/current           ← symlink → versions/3.12.13
└── bin/
    ├── python                ← shim (copia de pvm)
    └── pip                   ← shim (copia de pvm)

Compilar desde código fuente

Requiere Rust 1.70+.

Windows

git clone https://github.com/dh4r10/py-man
cd py-man
cargo build --release
# Binario en: target\release\pvm.exe

Para generar el instalador de Windows, instala Inno Setup 6 y ejecuta:

iscc installer\pvm.iss
# Instalador en: dist\pvm-setup-X.X.X.exe

Linux

git clone https://github.com/dh4r10/py-man
cd py-man
cargo build --release
# Binario en: target/release/pvm

Inspiración

Inspirado en fnm (Fast Node Manager) — misma filosofía aplicada al ecosistema Python.

🔝 Volver arriba

About

Python version manager for the terminal — single binary, no dependencies. Inspired by fnm. Supports Windows and Linux (x86_64 & aarch64).

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors