kennethreitz/envoy — pull request #25 by srathbun (2012-03-05 14:09:00+00:00)
Title: Checks platform.system to determine POSIX mode

This fixes a quoting issue with the shlex module in expand_args on windows. Under posix mode, words in `"` are expanded. So, `'cat "c:/program files/test.txt"'` gets passed in as `['cat', 'c:/program files/test.txt']`. With the double quotes removed, the underlying windows os sees two arguments, and fails to find either.

I've added a variable `POSIX` to hold `True` or `False` based upon the results from `platform.system()`. Anything that needs to check posix mode should use this value.