I am trying to pass the bash environment variable back to my fabric function as follows: -
from fabric.api import env
def env_localhost():
"All the environment variables relating to your localhost"
project_home = local('echo $PROJECT_HOME')
print 111, project_home
But it does not seem to be able to get stdout results and assign it to my python variable project_home. What is the right way to do it right?
source
share