os.path.expanduser('~/foo') and MSWindows "My Documents"

Tony Nelson *firstname*nlsnews at georgea*lastname*.com
Fri Nov 18 04:56:32 CET 2005

On *nix, ~/foo refers to a file in a user's home directory.  On 
MSWindows, users normally look at "My Documents" in their home 
directory.  ISTM that a file that my program would put in ~/. on Linux 
should be put in "~/My Documents/" (modulo os.path.normpath()) on 
MSWindows, where a user would expect it.  How do you guys cope with this 
TonyN.:'                        *firstname*nlsnews at georgea*lastname*.com
      '                                  <http://www.georgeanelson.com/>

More information about the Python-list mailing list