{"id":15898681,"url":"https://github.com/randomir/envie","last_synced_at":"2026-04-05T01:33:35.799Z","repository":{"id":27748550,"uuid":"31236498","full_name":"randomir/envie","owner":"randomir","description":"Python virtual environments wrangler.","archived":false,"fork":false,"pushed_at":"2019-04-12T05:23:47.000Z","size":270,"stargazers_count":22,"open_issues_count":6,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2026-03-19T22:02:39.786Z","etag":null,"topics":["python","shell","virtualenv"],"latest_commit_sha":null,"homepage":"http://envie.rtfd.io/","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/randomir.png","metadata":{"files":{"readme":"README.rst","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-02-23T23:54:43.000Z","updated_at":"2023-10-14T13:23:07.000Z","dependencies_parsed_at":"2022-09-03T17:52:04.540Z","dependency_job_id":null,"html_url":"https://github.com/randomir/envie","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/randomir/envie","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/randomir%2Fenvie","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/randomir%2Fenvie/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/randomir%2Fenvie/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/randomir%2Fenvie/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/randomir","download_url":"https://codeload.github.com/randomir/envie/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/randomir%2Fenvie/sbom","scorecard":{"id":761396,"data":{"date":"2025-08-11","repo":{"name":"github.com/randomir/envie","commit":"694f9f9ea6d2da8404c32ae409cf3cd70f437aa5"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.8,"checks":[{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Code-Review","score":0,"reason":"Found 1/29 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: pipCommand not pinned by hash: scripts/envie:418","Warn: pipCommand not pinned by hash: scripts/envie:420","Info:   0 out of   2 pipCommand dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 2 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-22T23:35:23.112Z","repository_id":27748550,"created_at":"2025-08-22T23:35:23.113Z","updated_at":"2025-08-22T23:35:23.113Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31421869,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-05T00:25:07.052Z","status":"ssl_error","status_checked_at":"2026-04-05T00:25:05.923Z","response_time":60,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["python","shell","virtualenv"],"created_at":"2024-10-06T10:07:27.969Z","updated_at":"2026-04-05T01:33:35.779Z","avatar_url":"https://github.com/randomir.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"Navigate and manage Python virtual environments\n===============================================\n\n.. image:: https://img.shields.io/pypi/v/envie.svg\n    :target: https://pypi.python.org/pypi/envie\n\n.. image:: https://img.shields.io/badge/platform-GNU/Linux,%20BSD,%20Darwin/OS%20X-red.svg\n    :target: https://pypi.python.org/pypi/envie\n\n.. image:: https://img.shields.io/badge/shell-bash-blue.svg\n    :target: https://pypi.python.org/pypi/envie\n\n.. image:: https://img.shields.io/pypi/pyversions/envie.svg\n    :target: https://pypi.python.org/pypi/envie\n\n.. image:: https://api.travis-ci.org/randomir/envie.svg?branch=master\n    :target: https://travis-ci.org/randomir/envie\n\n----\n\n*Envie* is a set of shell utilities (in ``bash``) aiming to increase your productivity\nwhen dealing with mundane Python virtual environment tasks, like creating, destroying,\nlisting/discovering, and switching/activating environments.\n\nWhere Envie really shines is auto-discovery, auto-activation and auto-creation of\nvirtual envs relevant to your project (or executable). It holds no assumptions on\nvirtual env dir location in relation to your code (or working directory),\nbut works best if they're near (nested, in level, or a few levels up).\n\n\nMotivation\n----------\n\nI like to keep my virtual environments close to source (especially in production).\nWith hundreds of projects on disk, this enables me to keep environment dir names short\nand project-relevant (since a project can have several environments, e.g. dev, prod, test).\nAlso, environments are easy to locate, update, or rebuild (maintain in general).\n\nIf you structure your files/projects in any of the ways depicted in Fig 1. below, you'll\nfind Envie particularly helpful.\n\n::\n\n    work                            work                                /srv\n    │                               │                                   │\n    ├── plucky                      ├── jsonplus                        ├── production\n    │   ├── env       \u003c--           │   ├── .git                        │   ├── website\n    │   ├── plucky                  │   ├── django                      │   │   ├── pythonenv     \u003c--\n    │   ├── tests                   │   │   ├── env                     │   │   ├── var\n    │   └── ...                     │   │   │   ├── dev      \u003c--        │   │   └── src\n    │                               │   │   │   └── prod     \u003c--        :   :       ├── .git\n    ├── blog                        │   │   ├── tests                   :   :       └── ...\n    │   ├── .env      \u003c--           │   │   │   ├── env      \u003c--        .   .\n    :   ├── .git                    :   :   :   ├── test_1.py\n    :   ├── _posts                  :   :   :   └── ...\n    .   └── ...                     .   .   .\n    \n    (a) env in level with src       (b) env nested under src           (c) env one level above src\n    \n    Figure 1. Several ways to keep your environments local to the code.\n\n\nEasy activation\n...............\n\nTo activate the closest virtual environment in vicinity, just type ``envie`` (Fig 1.a and 1.c):\n\n.. code-block:: bash\n\n    ~/work/plucky$ envie\n    Activated virtual environment at 'env'.\n\n    /srv/production/website/src$ envie\n    Activated virtual environment at '../pythonenv'.\n\nIf several equally close environments are found (Fig 1.b), you'll be prompted to select\nthe exact env. But, you can avoid it with a cunning use of fuzzy-filtering_, for example:\n\n.. code-block:: bash\n\n    ~/work/jsonplus$ envie dev\n    Activated virtual environment at 'django/env/dev'.\n\nDiscovery and filtering have no limits on depth, so you can activate your project environment like:\n\n.. code-block:: bash\n\n    ~$ envie plus dev\n    Activated virtual environment at 'work/jsonplus/django/env/dev'.\n\n\nImplicit activation\n...................\n\nSometimes you don't care about activating the relevant environment *in your shell*.\nYou just want your script to run in the correct env. Easy peasy (ref. Fig 1.b):\n\n.. code-block:: bash\n\n    ~/work/jsonplus$ envie ./django/tests/test_1.py\n    Activated virtual environment at 'django/tests/env'.\n    # running test ...\n\nIt doesn't have to be a Python script:\n\n.. code-block:: bash\n\n    ~/work/plucky$ envie run make test\n    Activated virtual environment at 'env'.\n    # running 'make' with python from env\n\nAnd it works from a hash bang too:\n\n.. code-block:: python\n\n    #!/usr/bin/env envie\n\nYou can even activate the closest environment after the fact, from your Python program\n(changing the environment from whatever was current — to the closest, relative to the script):\n\n.. code-block:: python\n\n    #!/usr/bin/python\n    import envie.activate_closest\n\n\nTerse \u0026 pip-infused create\n..........................\n\nSure, you can use ``virtualenv --python=python3 env``, but isn't this simpler?\n\n.. code-block:: bash\n\n    $ envie create\n    \n    # or, shorter:\n    $ mkenv\n\nAnd how about also **installing** your **pip requirements** in one go?\n\n.. code-block:: bash\n\n    $ mkenv -r dev-requirements.txt env/dev\n\nOr, creating a **temporary/throw-away** environment **with** some **packages** installed, then\nhacking in an interactive Python session, and finally destroying the complete environment upon exit:\n\n.. code-block:: bash\n\n    $ mkenv -t -p requests -p 'plucky\u003e=0.4' \u0026\u0026 python \u0026\u0026 rmenv -f\n\nDetails and more examples are available in `envie create`_, `envie remove`_, and `envie-tmp`_ docs.\n\n\nExisting environments discovery\n...............................\n\nActivation of the closest environment is predicated on the discovery of the existing virtual\nenvironments below a certain directory with ``lsenv`` (`envie list`_), and on the up-the-tree\nsearch with ``findenv`` (`envie find`_):\n\n.. code-block:: bash\n\n    ~/work$ lsenv\n    plucky/env\n    blog/.env\n    jsonplus/django/env/dev\n    ...\n\n\n.. _chenv: http://envie.readthedocs.io/en/latest/commands.html#chenv\n.. _fuzzy-filtering: http://envie.readthedocs.io/en/latest/commands.html#fuzzy-filtering\n.. _`envie create`: http://envie.readthedocs.io/en/latest/commands.html#mkenv\n.. _`envie remove`: http://envie.readthedocs.io/en/latest/commands.html#rmenv\n.. _`envie-tmp`: http://envie.readthedocs.io/en/latest/commands.html#envie-tmp\n.. _`envie list`: http://envie.readthedocs.io/en/latest/commands.html#lsenv\n.. _`envie find`: http://envie.readthedocs.io/en/latest/commands.html#findenv\n\n\nInstall \u0026 configure\n-------------------\n\nFor convenience, ``envie`` is packaged and distributed as a Python package.\nYou can install it system-wide (or user-local, see `Install`_ docs):\n\n.. code-block:: bash\n\n    $ sudo pip install envie\n    $ envie config\n\n    # don't forget to source envie:\n    $ . ~/.bashrc\n    \n    # or just open a new shell\n\nAfter install, be sure to run a (short and interactive) `configuration`_ procedure with ``envie config``.\nIf in doubt, go with the defaults. Running config is optional, but recommended.\nIt'll, for example, allow to you easily add Envie sourcing statement to your ``.bashrc``\n(enabling Bash completion and alias functions), and to activate environments indexing\n(enabling faster search with ``locate``).\n\n.. _Install: http://envie.readthedocs.io/en/latest/setup.html#install\n.. _configuration: http://envie.readthedocs.io/en/latest/setup.html#configure\n\n\nEnable index\n............\n\nBy default, ``envie`` uses the ``find`` command to search for environments. That\napproach is pretty fast when searching shallow trees. However, if you have\ndeeper directory trees, it's often faster to use a pre-built directory index\n(i.e. the ``locate`` command). To configure a combined ``locate/find`` approach to\nsearch, run ``envie config``.\n\nWhen index is enabled, the combined approach is used by default (if not overriden with\n``-f`` or ``-l`` switches). In the combined approach, ``find`` and ``locate`` start searching\nin parallel and vie for producing results first. However, ``find`` is given only 400ms to finish\nbefore being terminated, thusly producing ``locate``-based results for deeper trees faster\n(but potentially incomplete if index was stale).\n\n\nTesting\n.......\n\nRun all test suites locally with::\n\n    $ make test\n\n(after cloning the repo.)\n\n\nUsage in short\n--------------\n\n``envie [-1] [-f|-l] [\u003cbasedir\u003e] [\u003ckeywords\u003e]`` (alias ``chenv``)\n    Interactively activate the closest environment (looking down, then up, with ``findenv``), optionally filtered by a list of ``\u003ckeywords\u003e``. Start looking in ``\u003cbasedir\u003e`` (defaults to ``.``).\n\n``envie create [-2|-3|-e \u003cpyexec\u003e] [-r \u003cpip_req\u003e] [-p \u003cpip_pkg\u003e] [-a] [\u003cenvdir\u003e | -t]`` (alias ``mkenv``)\n    Create virtual environment in ``\u003cenvdir\u003e`` (or in a temporary dir, ``-t``) based on a Python interpreter ``\u003cpyexec\u003e``, optionally installing Pip requirements from ``\u003cpip_req\u003e`` file, and/or ``\u003cpip_pkg\u003e`` requirement specifier(s).\n\n``envie remove`` (alias ``rmenv``)\n    Destroy the active environment.\n\n``envie list [-f|-l] [\u003cdir\u003e] [\u003ckeywords\u003e]`` (alias ``lsenv``)\n    List all environments below ``\u003cdir\u003e`` directory, optionally filtered with a list of ``\u003ckeywords\u003e``.\n\n``envie find [-f|-l] [\u003cdir\u003e] [\u003ckeywords\u003e]`` (alias ``findenv``)\n    Find the closest environments by first looking down and then dir-by-dir up the tree, starting in ``\u003cdir\u003e``; optionally filtered with a list of ``\u003ckeywords\u003e``.\n\n``envie \u003cscript\u003e``, ``envie python \u003cscript\u003e``\n    Run Python ``script`` in the closest virtual environment.\n\n``envie run \u003ccommand\u003e``\n    Execute arbitrary ``command/builtin/file/alias/function`` in the closest virtual environment.\n\n``envie-tmp \u003cscript\u003e``\n    Create a new temporary (throw-away) virtual environment, install requirements specified inside the ``\u003cscript\u003e`` file, run the ``\u003cscript\u003e``, and destroy the environment afterwards.\n\n``envie config``\n    Interactively configure Envie.\n\n``envie index``\n    (Re-)index virtual environments (for faster searches with ``locate``).\n\n``envie help``\n    Print usage help. For details on a specific command use the ``-h`` switch (like ``envie find -h``, or ``mkenv -h``).\n\n\nDocumentation\n-------------\n\nDocumentation is hosted by ReadTheDocs, latest version being available at `envie.rtfd.io \u003chttp://envie.rtfd.io/\u003e`_.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frandomir%2Fenvie","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frandomir%2Fenvie","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frandomir%2Fenvie/lists"}