[issue16353] add function to os module for getting path to default shell
Christian Heimes
report at bugs.python.org
Mon Nov 5 20:16:37 CET 2012
Christian Heimes added the comment:
I've tested confstr("CS_PATH") on Linux, Mac OS X, Solaris, HP-UX and BSD. It works and the path to `sh` is always included.
Taras:
You don't have to perform the platform inside the get_shell() function. I suggest that you define the function depending on the value of `name`.
if name == "posix":
def get_shell():
...
elif name in {"nt", "ce"}:
def get_shell():
...
----------
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue16353>
_______________________________________
More information about the Python-bugs-list
mailing list