I pulled (git) a python project which was created (by me on another computer) using virtualenv. So, the python library is actually in a local directory (e.g., fila_env/bin/python
) in this project. After pulling it, I can locate that (see the tree below). However, when I activate the environment (using source fila_env/bin/activate
), the python on this machine is being used instead of the virtualenv's:
(fila_env) username@ASCSC-645A:~/CODES/.../myProject$ which python
>>> /usr/bin/python
I googled around but I couldn't find a good solution to this. I would like to know:
- How I can assure that if someone pulls this project, they will only use the provided python library, and not their own python.
- Is this a correct approach to create a virtualenv, and push the entire project (including the virtualenv) to the cloud?
Here are some more info:
├── yyyyyyExample.py
├── fila_env
│ ├── bin
│ │ ├── activate
│ │ ├── ...
│ │ ├── python
│ │ ├── python2 -> python
│ │ ├── python2.7 -> python
│ │ ├── python-config
│ │ ├── ...
│ │ └── wheel
│ ├── include
│ │ └── python2.7 -> /usr/include/python2.7
│ ├── lib
│ │ └── python2.7
│ ├── local
│ │ ├── bin -> .../fila_env/bin
│ │ ├── include -> .../fila_env/include
│ │ └── lib -> .../fila_env/lib
│ ├── pip-selfcheck.json
│ └── share
│ ├── jupyter
│ └── man
└── xxxxxxExample.py