veman


Nameveman JSON
Version 0.3.0 PyPI version JSON
download
home_page
SummaryVirtual environment manager for venv
upload_time2023-11-28 19:40:36
maintainer
docs_urlNone
authorMikael Tranbom
requires_python>=3.9
licenseGPLv3
keywords venv virtual environment utility developer tools virtual environment manager
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # veman - Virtual Environment Manager

[![pipeline status](https://gitlab.com/tranbom/veman/badges/main/pipeline.svg)](https://gitlab.com/tranbom/veman/-/pipelines)
[![PyPi - Release](https://img.shields.io/pypi/v/veman)](https://pypi.org/project/veman/)
[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/veman)](https://pypi.org/project/veman/)
[![PyPI - License](https://img.shields.io/pypi/l/veman?color=blue)](https://pypi.org/project/veman/)

veman is a lightweight virtual environment manager using venv.
With veman it is easier to manage multiple environments.

Note: veman is under active development and currently supports Bash in FreeBSD, Linux & macOS.

veman aims to be a simple manager for Python's venv package. The intention of veman is
to be a comprehensive companion tool for venv, facilitating the creation/activation &
management of virtual environments, with some extra features that aids development with
Python.

veman is primarily developed for Linux & macOS. veman does not yet support
Windows. Windows compatibility will most likely be implemented in a future version but it is
currently not a prioritised feature.

* GitHub: [https://github.com/tranbom/veman](https://github.com/tranbom/veman)
* GitLab: [https://gitlab.com/tranbom/veman](https://gitlab.com/tranbom/veman)
* PyPi: [https://pypi.org/project/veman](https://pypi.org/project/veman)
* Documentation: [https://tranbom.io/veman/](https://tranbom.io/veman/)


## Installation

Install via pipx:
`pipx install veman`

Using pipx is the preferred method to install veman.

Installing with pip is not supported when the Python environment is externally managed
(for example in Debian 12), see PEP-668 for more information.

The default installation directory used by pipx is `~/.local/bin` which needs to be in your PATH.
Update the PATH manually or run `pipx ensurepath`.

### Dependencies

- Python >=3.9
- venv

### Installation instructions for Debian 12 and distributions based on Debian 12

Install pip, pipx & venv from the Debian repository:  
`sudo apt-get update`  
`sudo apt-get install python3-pip python3-venv pipx`  

Install veman with pipx and update PATH (if necessary):  
`pipx install veman`  
`pipx ensurepath`  

## Usage

### Create a new virtual environment

`veman create` or
`veman create <environment-name>`

Use `-a` or `--activate` after the create command to automatically activate
the venv after creation.

Examples:  
`veman create djangoenv`  
`veman create -a flaskenv`  
`veman create --activate testenv1`  


### Activate a virtual environment

`veman activate` or
`veman activate <environment-name>`

Example:
`veman activate djangoenv`


### Deactivate a virtual environment

`deactivate` (inside an active venv)


### List created virtual environments

`veman list`


### Delete a virtual environment

`veman delete` or `veman delete <environment-name>`

Example: `veman delete djangoenv`


### Create and activate a temporary environment

Create a temporary environment which will be deleted immediately when
deactivating the environment.

`veman temp`

To exit & delete the temporary environment type `deactivate`

veman supports creating multiple temporary environments simultaneously.


### Bash history

veman creates a separate bash history file for each venv.

The history of bash commands executed inside an activated venv is saved
in the root folder of the venv as **.veman_history** and everytime
a virtual environment is activated the bash history will be restored.

The bash builtin `history` will print the environments history when a venv is activated and
when the virtual environment is deactivated `history` will automatically switch back to using
the regular bash history file (usually ~/.bash_history).

veman also has its own `history` command which can be used without having to activate
a venv, making it easy to find which commands have been run in different environments.

`veman history <environment-name>` will list the bash history for a single venv.

`veman history --all` will print the bash history for all venvs, which can be useful to
quickly find a command in the history across environments. Currently there is no specific order of the
venvs in which the history is printed.

The `--verbose` option will print some additional details, such as venv name and line number.


### Upgrade venv

Various components of a venv can be upgraded with veman.
Running `veman upgrade <environment-name>` will upgrade the following:

- Core dependencies (pip + setuptools)
- Python (will be upgraded to the python version running the veman command)
- veman scripts

It is also possible to select which components to upgrade using any of the following options when running `veman upgrade`:

- `--deps` - Upgrade core dependencies
- `--python` - Upgrade Python
- `--scripts` - Upgrade veman scripts

Upgrading the veman scripts can be useful when a new version of veman has been released to ensure compatibility of new
veman features in a venv created with an older version of veman.

All managed venvs can be upgraded with the option `--all`:

`veman upgrade --all`


### Full list of available commands and options

* Documentation: [https://tranbom.io/veman/](https://tranbom.io/veman/)


## Notes

veman sources `~/.bashrc` in Linux & FreeBSD. veman is mainly tested in distributions that are
derivatives of Debian which automatically sources `/etc/bash.bashrc`.

veman sources `/etc/profile` and `~/.bash_profile` in macOS.


## Planned features

- Connect a managed venv with a specific git repository (e.g., automatic cd on activate)
- User defined commands to run on activate (python and/or shell)
- Compatibility with zsh & more shells
- Command to add local paths to .pth-file in venv
- Configuration file with settings for veman (e.g., path to env directory)
- Adopt existing unmanaged venvs
- Auto-update managed venvs after veman has been upgraded


## License

GPL-3.0-only

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "veman",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.9",
    "maintainer_email": "",
    "keywords": "venv,virtual environment,utility,developer tools,virtual environment manager",
    "author": "Mikael Tranbom",
    "author_email": "mikael@tranbom.io",
    "download_url": "https://files.pythonhosted.org/packages/2a/b2/50d3828b21f3ca6c47f51d82469b73a3af9b7aa711bc32323d6cfeecc3d0/veman-0.3.0.tar.gz",
    "platform": null,
    "description": "# veman - Virtual Environment Manager\n\n[![pipeline status](https://gitlab.com/tranbom/veman/badges/main/pipeline.svg)](https://gitlab.com/tranbom/veman/-/pipelines)\n[![PyPi - Release](https://img.shields.io/pypi/v/veman)](https://pypi.org/project/veman/)\n[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/veman)](https://pypi.org/project/veman/)\n[![PyPI - License](https://img.shields.io/pypi/l/veman?color=blue)](https://pypi.org/project/veman/)\n\nveman is a lightweight virtual environment manager using venv.\nWith veman it is easier to manage multiple environments.\n\nNote: veman is under active development and currently supports Bash in FreeBSD, Linux & macOS.\n\nveman aims to be a simple manager for Python's venv package. The intention of veman is\nto be a comprehensive companion tool for venv, facilitating the creation/activation &\nmanagement of virtual environments, with some extra features that aids development with\nPython.\n\nveman is primarily developed for Linux & macOS. veman does not yet support\nWindows. Windows compatibility will most likely be implemented in a future version but it is\ncurrently not a prioritised feature.\n\n* GitHub: [https://github.com/tranbom/veman](https://github.com/tranbom/veman)\n* GitLab: [https://gitlab.com/tranbom/veman](https://gitlab.com/tranbom/veman)\n* PyPi: [https://pypi.org/project/veman](https://pypi.org/project/veman)\n* Documentation: [https://tranbom.io/veman/](https://tranbom.io/veman/)\n\n\n## Installation\n\nInstall via pipx:\n`pipx install veman`\n\nUsing pipx is the preferred method to install veman.\n\nInstalling with pip is not supported when the Python environment is externally managed\n(for example in Debian 12), see PEP-668 for more information.\n\nThe default installation directory used by pipx is `~/.local/bin` which needs to be in your PATH.\nUpdate the PATH manually or run `pipx ensurepath`.\n\n### Dependencies\n\n- Python >=3.9\n- venv\n\n### Installation instructions for Debian 12 and distributions based on Debian 12\n\nInstall pip, pipx & venv from the Debian repository:  \n`sudo apt-get update`  \n`sudo apt-get install python3-pip python3-venv pipx`  \n\nInstall veman with pipx and update PATH (if necessary):  \n`pipx install veman`  \n`pipx ensurepath`  \n\n## Usage\n\n### Create a new virtual environment\n\n`veman create` or\n`veman create <environment-name>`\n\nUse `-a` or `--activate` after the create command to automatically activate\nthe venv after creation.\n\nExamples:  \n`veman create djangoenv`  \n`veman create -a flaskenv`  \n`veman create --activate testenv1`  \n\n\n### Activate a virtual environment\n\n`veman activate` or\n`veman activate <environment-name>`\n\nExample:\n`veman activate djangoenv`\n\n\n### Deactivate a virtual environment\n\n`deactivate` (inside an active venv)\n\n\n### List created virtual environments\n\n`veman list`\n\n\n### Delete a virtual environment\n\n`veman delete` or `veman delete <environment-name>`\n\nExample: `veman delete djangoenv`\n\n\n### Create and activate a temporary environment\n\nCreate a temporary environment which will be deleted immediately when\ndeactivating the environment.\n\n`veman temp`\n\nTo exit & delete the temporary environment type `deactivate`\n\nveman supports creating multiple temporary environments simultaneously.\n\n\n### Bash history\n\nveman creates a separate bash history file for each venv.\n\nThe history of bash commands executed inside an activated venv is saved\nin the root folder of the venv as **.veman_history** and everytime\na virtual environment is activated the bash history will be restored.\n\nThe bash builtin `history` will print the environments history when a venv is activated and\nwhen the virtual environment is deactivated `history` will automatically switch back to using\nthe regular bash history file (usually ~/.bash_history).\n\nveman also has its own `history` command which can be used without having to activate\na venv, making it easy to find which commands have been run in different environments.\n\n`veman history <environment-name>` will list the bash history for a single venv.\n\n`veman history --all` will print the bash history for all venvs, which can be useful to\nquickly find a command in the history across environments. Currently there is no specific order of the\nvenvs in which the history is printed.\n\nThe `--verbose` option will print some additional details, such as venv name and line number.\n\n\n### Upgrade venv\n\nVarious components of a venv can be upgraded with veman.\nRunning `veman upgrade <environment-name>` will upgrade the following:\n\n- Core dependencies (pip + setuptools)\n- Python (will be upgraded to the python version running the veman command)\n- veman scripts\n\nIt is also possible to select which components to upgrade using any of the following options when running `veman upgrade`:\n\n- `--deps` - Upgrade core dependencies\n- `--python` - Upgrade Python\n- `--scripts` - Upgrade veman scripts\n\nUpgrading the veman scripts can be useful when a new version of veman has been released to ensure compatibility of new\nveman features in a venv created with an older version of veman.\n\nAll managed venvs can be upgraded with the option `--all`:\n\n`veman upgrade --all`\n\n\n### Full list of available commands and options\n\n* Documentation: [https://tranbom.io/veman/](https://tranbom.io/veman/)\n\n\n## Notes\n\nveman sources `~/.bashrc` in Linux & FreeBSD. veman is mainly tested in distributions that are\nderivatives of Debian which automatically sources `/etc/bash.bashrc`.\n\nveman sources `/etc/profile` and `~/.bash_profile` in macOS.\n\n\n## Planned features\n\n- Connect a managed venv with a specific git repository (e.g., automatic cd on activate)\n- User defined commands to run on activate (python and/or shell)\n- Compatibility with zsh & more shells\n- Command to add local paths to .pth-file in venv\n- Configuration file with settings for veman (e.g., path to env directory)\n- Adopt existing unmanaged venvs\n- Auto-update managed venvs after veman has been upgraded\n\n\n## License\n\nGPL-3.0-only\n",
    "bugtrack_url": null,
    "license": "GPLv3",
    "summary": "Virtual environment manager for venv",
    "version": "0.3.0",
    "project_urls": {
        "Documentation": "https://tranbom.io/veman/",
        "Homepage": "https://tranbom.io/veman/",
        "Repository": "https://gitlab.com/tranbom/veman"
    },
    "split_keywords": [
        "venv",
        "virtual environment",
        "utility",
        "developer tools",
        "virtual environment manager"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "5fcaf756b3ee842ab4eb8ee0e7193b075280be91502cece509a6ed04f5346d51",
                "md5": "a4a7adb6bd725c5247a9cf3beb51c0cb",
                "sha256": "c9688c11a69c9f8fdd6fae4ea20d3bda0358e24592e8972168068ea4b7eb9181"
            },
            "downloads": -1,
            "filename": "veman-0.3.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "a4a7adb6bd725c5247a9cf3beb51c0cb",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.9",
            "size": 23435,
            "upload_time": "2023-11-28T19:40:34",
            "upload_time_iso_8601": "2023-11-28T19:40:34.375684Z",
            "url": "https://files.pythonhosted.org/packages/5f/ca/f756b3ee842ab4eb8ee0e7193b075280be91502cece509a6ed04f5346d51/veman-0.3.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "2ab250d3828b21f3ca6c47f51d82469b73a3af9b7aa711bc32323d6cfeecc3d0",
                "md5": "44ff47ada30ce5ea6dc0d1e79d60dff9",
                "sha256": "c70b08be0fc49abc18f5e9fe62aa82e80ee162048da73bccfbf312bfa8d29dde"
            },
            "downloads": -1,
            "filename": "veman-0.3.0.tar.gz",
            "has_sig": false,
            "md5_digest": "44ff47ada30ce5ea6dc0d1e79d60dff9",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.9",
            "size": 23819,
            "upload_time": "2023-11-28T19:40:36",
            "upload_time_iso_8601": "2023-11-28T19:40:36.473091Z",
            "url": "https://files.pythonhosted.org/packages/2a/b2/50d3828b21f3ca6c47f51d82469b73a3af9b7aa711bc32323d6cfeecc3d0/veman-0.3.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-11-28 19:40:36",
    "github": false,
    "gitlab": true,
    "bitbucket": false,
    "codeberg": false,
    "gitlab_user": "tranbom",
    "gitlab_project": "veman",
    "lcname": "veman"
}
        
Elapsed time: 0.18279s