[Python] How does one enter a Python virtualenv when executing a bashscript?

Discussão em 'Python' iniciado por Stack, Março 4, 2025.

  1. Stack

    Stack Membro Participativo

    If one defines which version of python to use in a bash script, it would be

    export PYTHON = "/path/python/python-3.5.1/bin/python"


    But for Python virtualenv's, one executes these commands in the command line

    cd /path/pathto/virtualenv
    source activate
    cd another_directory


    How does one "enter" a Python virtualenv in a bash script? What is the standard approach here?

    Continue reading...

Compartilhe esta Página