Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Readme - install dependencies in virtual environment #23

Open
cpu opened this issue Jul 23, 2017 · 0 comments
Open

Readme - install dependencies in virtual environment #23

cpu opened this issue Jul 23, 2017 · 0 comments

Comments

@cpu
Copy link
Collaborator

cpu commented Jul 23, 2017

Suggested by @krzysztofr in StreisandEffect/streisand#8

It is considered good practice to install any external python libraries in the virtual environment (using virtualenv, docs here), so you don't contaminate your system and have control over the different versions of libraries for different projects.
Such environment could be in any situation easily destroyed and recreated.

So, instead of, for example:
sudo pip install boto

You should create and activate virtual environment:

sudo pip install virtualenv
virtualenv venv
source venv/bin/activate

and install external dependencies locally, in the context of this environment:
pip install boto

Moreover, you can create list of all dependencies:
pip freeze > requirements.txt

...and then install them with one command:
pip install -r requirements.txt

If you find my comment useful I can modify Readme file or, if it is needed, provide more detailed explanation.

PRs welcome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant