Paczesiowa/virthualenv — Issue #34: support multiple envs in one project directory
Author: simonmichael
Created: 2012-02-01 21:00:17+00:00
State: open

Thanks for virthualenv. I'd like to use it to test a project with different ghc and package sets, without having to duplicate the project directory. The --name option didn't do what I expected - virthualenv always uses the ".virthualenv" path. Here's a bash alias I use for switching, but making --name set the directory name seems better.

# activate the named .virthualenv environment ("deactivate" to exit)
function activate ()
{
if [ "$1" == "" ]
then
echo environments available: `ls -d .virthualenv-*`
else
rm -f .virthualenv
ln -s .virthualenv-"$1" .virthualenv
source .virthualenv-"$1"/bin/activate
fi
}