Per user dirs on Non-Unix platforms (was Re: [Python-Dev] Where to install non-code files) (original) (raw)
Fred L. Drake fdrake@acm.org
Tue, 30 May 2000 07:22:42 -0700 (PDT)
- Previous message: Per user dirs on Non-Unix platforms (was Re: [Python-Dev] Where to install non-code files)
- Next message: Per user dirs on Non-Unix platforms (was Re: [Python-Dev] Where to install non-code files)
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Sun, 28 May 2000, Guido van Rossum wrote:
Idea: Wouldn't it be nice if the 'nt' and 'mac' versions of the 'os' module would provide 'os.environ["HOME"]' similar to the posix version? This would certainly simplify the task of application programmers intending to write portable applications.
This sounds like a nice idea...
Now that this idea has fermented for a few days, I'm inclined to not like it. It smells of making Unix-centric interface to something that isn't terribly portable as a concept. Perhaps there should be a function that does the "right thing", extracting os.environ["HOME"] if defined, and taking an alternate approach (os.getcwd() or whatever) otherwise. I don't think setting os.environ["HOME"] in the library is a good idea because that changes the environment that gets published to child processes beyond what the application does.
-Fred
-- Fred L. Drake, Jr.
- Previous message: Per user dirs on Non-Unix platforms (was Re: [Python-Dev] Where to install non-code files)
- Next message: Per user dirs on Non-Unix platforms (was Re: [Python-Dev] Where to install non-code files)
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]