customary way of keeping your own Python and module directory in $HOME

Christopher Arndt chris.arndt at web.de
Mon May 21 13:16:28 EDT 2007


On 15 Mai, 02:55, jmg3... at gmail.com wrote:
> My issues have been with keeping a ~/pylib directory for extra
> modules, and reconciling that with setuptools / Easy Install. I'm
> curious to hear how other folks manage their own local module
> directory.

For Python libraries, I use the workingenv.py (search Cheeseshop) for
keeping a separate environment for every application with all the
libraries it needs. This is great to dodge problems with two apps
requiring different, uncompatible versions of the same library, for
having different staging and production environments, and so on.

Once you activate an environment (in a shell or in your Python
script), the PYTHONPATH and the installation directories for distutils
and easy_install will be adapted automatically.

Chris




More information about the Python-list mailing list