edc / bass

Make Bash utilities usable in Fish shell
MIT License
2.2k stars 70 forks source link

Use Python to Robustly Read Environment Variables #16

Closed edc closed 8 years ago

edc commented 8 years ago

Fixes #15.

Bass uses /usr/bin/env to read environment variables. It is not able to handle multi-line environment variables, among other edge cases.

This PR updates it to use os.environ in Python to read environment variables and dump them to JSON. This is much more robust and should be able to handle most edge cases.