Adding paths to sys.path permanently, and another problem...
adekel at ort.org.il
Fri Dec 17 14:24:45 CET 2004
Jeff Shannon wrote:
> Judging from this, I think that os.environ['USERPROFILE'] seems like it
> may do what you want, though os.environ['APPDATA'] might be useful as
> well. Of course, if you're trying to get something to work
> cross-platform, things may be more difficult -- but that's because
> Windows doesn't normally use ~ so its use is not supported very well.
> You may be able to create a $HOME that's equivalent to $USERPROFILE...
Both problems solved! The .pth seems like the best solution for the
first one, and for the expanduser("~") I just added a $HOME variable to
the Environment variables of WinXP. Simple solutions. Thanks Jeff
More information about the Python-list