Kirusi / hook-run

Python bootstrap to activate a virtual environment (venv, or conda) and run a command. Intended to be used with pre-commit pypi package. Inspired by venv-run

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

hook-run

Python bootstrap to activate a virtual environment (venv, or conda) and run a command. Intended to be used with pre-commit pypi package. Inspired by venv-run

Runs a command from an existing python virtual environment. Script looks for a private configuration file in the current working directory hook-run.json. If such file is found, it's expected to follow format:

{
    "path": "/home/user/my_project/venv/bin"
}

Where path points to the virtual environment to be used. If configuration file is not found, then no bootstrapping is performed, but script proceeds with command execution

After bootstrapping is done, then specified command is executed.

About

Python bootstrap to activate a virtual environment (venv, or conda) and run a command. Intended to be used with pre-commit pypi package. Inspired by venv-run

License:MIT License


Languages

Language:Python 100.0%