This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author paul.moore
Recipients paul.moore, vinay.sajip
Date 2013-07-17.10:11:07
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1374055868.56.0.0556139473307.issue18479@psf.upfronthosting.co.za>
In-reply-to
Content
Some small improvements to the powershell "Activate" script for venvs:

1. Can be run as a command, rather than needing to be dot sourced. This matches the behaviour of bat files, and of virtualenv's "activate" script, and avoids a source of user error.

2. Makes the "deactivate" command a function, so that a separate script is not needed, and deactivate can still be run after the environment has been deleted (a common error I make is to remove a temporary venv having forgotten to deactivate it first).

3. Corrects the prompt to have a prefix (name) rather than [(name) ]. This is likely a bug in venv itself, as __VENV_NAME__ is documented as being just the name, not the prompt string. But changing that could be a backward compatibility issue, so I'd prefer to put that in a separate patch if it's needed.

These modifications are based on the virtualenv activate.ps1 script, which has been in use for some time, so they should be relatively well tested.
History
Date User Action Args
2013-07-17 10:11:08paul.mooresetrecipients: + paul.moore, vinay.sajip
2013-07-17 10:11:08paul.mooresetmessageid: <1374055868.56.0.0556139473307.issue18479@psf.upfronthosting.co.za>
2013-07-17 10:11:08paul.moorelinkissue18479 messages
2013-07-17 10:11:08paul.moorecreate