Skip to main content

Run commands using Python virtual environment

Project description

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.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hook-run-1.1.0.tar.gz (2.1 kB view details)

Uploaded Source

File details

Details for the file hook-run-1.1.0.tar.gz.

File metadata

  • Download URL: hook-run-1.1.0.tar.gz
  • Upload date:
  • Size: 2.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.7

File hashes

Hashes for hook-run-1.1.0.tar.gz
Algorithm Hash digest
SHA256 2a6436527d8061e9314df2f727cf585a2662d1494e1a2c3ab43e3a7f65482415
MD5 780de2cadbddd444ff9666531ab2d88d
BLAKE2b-256 6169d333b178073a28db4254ea4281a41bcdda923a28aa02ff446a4e9516d7a8

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page