Automatically creating a HOME environ variable on Windows?
Jarek Zgoda
jzgoda at o2.usun.pl
Sat Oct 29 05:46:14 EDT 2005
jim.eggleston at gmail.com napisał(a):
> Windows doesn't have a HOME environment variable, but it does have
> HOMEDRIVE and HOMEPATH. Could Windows versions of Python automatically
> populate os.environ with HOME, where HOME =
> os.path.join(os.environ['HOMEDRIVE'], os.environ['HOMEPATH'])?
MS recommends using %USERPROFILE%, as the above in many cases returns
"C:\", which is wrong.
--
Jarek Zgoda
http://jpa.berlios.de/
More information about the Python-list
mailing list