A library that allows you to execute python code
npm install python-runner -g
The only dependencies of this package are:
## Usage
The execution function will run send every command to the python stdin interpreter returning a Q promise. This will be resolved with the stdout of the python binary.
The python binary will be executed with the same environment variables as its parent process.
You can tweak the following options:
- bin - The python binary to be used
- env - Replace the environment variables for this python execution. Useful for PYTHONPATH, ...
var python = requrie("python-runner");
python.exec(
"print('Carma Carpooling - Get there together')",
{
/// set which version of python to use
bin: "python",
env: {
/// set the PYTHONPATH of the current execution
PYTHONPATH: "...."
}
})
/// get the stdout
.then(function(stdout){
})
/// catch the error
.then(function(err){
});


