amoffat / sh

Python process launching

Home Page:https://sh.readthedocs.io/en/latest/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support for 'source'

hengruo opened this issue · comments

A feature like "source xxx.sh" is needed.
I tried "sh.bash("-c", "source xxx.sh")" but the environment variables in xxx.sh weren't imported into the current environment.

I feel strongly that this is outside of the scope of sh. To be more specific, the goal of sh is to make calling commands like calling functions. What you have described is making python more like bash.