Skip to content

setup_virtualenv.sh: add a basic virtualenv setup script #3

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions setup_virtualenv.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
#!/bin/bash

# Setup script for installing into a virtualenv to avoid messing with
# system packages

if [ ! -e /usr/bin/virtualenv ] ; then
echo -e "virtualenv NOT found, run sudo easy_install virtualenv"
exit 1
fi

export VIRTUALENV_PATH=${PWD}/virtualenv
virtualenv --no-site-packages $VIRTUALENV_PATH
source $VIRTUALENV_PATH/bin/activate

if [ ! -e $VIRTUALENV_PATH/bin/nosetests ] ; then
easy_install nose
fi

pip install -r requirements.txt

echo "Run \"source $VIRTUALENV_PATH/bin/activate\" to activate this virtualenv."