Skip to content

theajack/venv-manager

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

VENV Manager

中文文档

Interactive terminal selectors for Conda environments and Python venvs, with arrow-key navigation, creation, deletion, and activation — all in one command.

npm i -g venv-manager

cvem  # Conda env selector
pvem  # Python venv selector

# Or use directly without install:

source <(curl -fsSL https://cdn.jsdelivr.net/gh/theajack/venv-manager/scripts/cvem.sh)
source <(curl -fsSL https://cdn.jsdelivr.net/gh/theajack/venv-manager/scripts/pvem.sh)
Command Description
cvem Conda environment selector — list / create / delete / activate conda envs
pvem Python venv selector — find / create / delete / activate venvs

Quick Start (CDN — No Install)

Run directly via jsDelivr CDN — nothing to install:

# Conda environment selector
source <(curl -fsSL https://cdn.jsdelivr.net/gh/theajack/venv-manager/scripts/cvem.sh)

# Python venv selector
source <(curl -fsSL https://cdn.jsdelivr.net/gh/theajack/venv-manager/scripts/pvem.sh)

Install via npm

npm install -g venv-manager

After installation, the postinstall script automatically adds cvem and pvem shell functions to your ~/.zshrc or ~/.bashrc.

Open a new terminal (or run source ~/.zshrc) and then:

# Conda environment selector
cvem

# Python venv selector
pvem

Manual Setup

If the auto-setup didn't run, you can trigger it manually:

vem-setup

Or add the functions yourself:

# Add to ~/.zshrc or ~/.bashrc
cvem() { source "$(npm prefix -g)/lib/node_modules/venv-manager/scripts/cvem.sh"; }
pvem() { source "$(npm prefix -g)/lib/node_modules/venv-manager/scripts/pvem.sh"; }

Usage

cvem — Conda Environment Selector

↑/↓  Navigate
Enter  Activate selected environment
n  Create new environment (with Python version selector)
d  Delete selected environment
q  Quit

pvem — Python Venv Selector

Searches for venvs in the current directory (depth 3) and common locations (~/.venvs, ~/venvs, ~/.virtualenvs).

↑/↓  Navigate
Enter  Activate selected venv
n  Create new venv (with Python interpreter selector)
d  Delete selected venv
q  Quit

Requirements

  • bash or zsh
  • cvem: conda installed and available in PATH
  • pvem: Python 3 with venv module

License

MIT

About

Conda and python virtual environment manager / 虚拟环境管理工具

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors