[Tutor] Linux Home directory

Shitiz Bansal shitizb at yahoo.com
Fri Mar 12 20:54:12 EST 2004

The required code is:
import commands
x= commands.getstatusoutput('echo $HOME')
x[1] gives the value of required directory as string.

Mike Wagman <mwagman at charter.net> wrote:
How can I tell using python what the user that is running the softwares
home directory is. I need it so I can finish a linux app and save config
files (etc) in that directory.


Tutor maillist - Tutor at python.org

Do you Yahoo!?
Yahoo! Search - Find what you’re looking for faster.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/tutor/attachments/20040312/c7d1bedf/attachment.html

More information about the Tutor mailing list