Now that IronPython runs on other operating systems, what is the recommended
way to determine the os when running IP?
sys.platform returns 'cli' across all, and sys.builtin_module_names includes
'nt' on all.
Perhaps something like:
def platform():
data = sys.getwindowsversion() # major, minor, build, platform, service_pack
if data.platform in [0, 1, 2, 3] return "win"
elif data.platform == 4: return "linux"
...
"cli" isn't really the platform; it is the type of Python. Perhaps this should
be fixed as we go forward.
-Doug
_______________________________________________
Users mailing list
[email protected]
http://lists.ironpython.com/listinfo.cgi/users-ironpython.com