python 取得当前用户的Home目录

 os.environ['HOME']

 os.path.expandvars('$HOME')

 os.path.expanduser('~')

猜你喜欢

转载自scm002.iteye.com/blog/2248777