Package Exports
- sb-exec
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (sb-exec) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Exec
Node's Process spawning APIs beautified
Installation
npm install --save sb-execAPI
type $Options = {
timeout?: number | Infinity,
stream?: 'stdout' | 'stderr' | 'both',
env: Object,
stdin?: ?string,
local?: {
directory: string,
prepend?: boolean
},
throwOnStdErr?: boolean = true,
allowEmptyStderr?: boolean = false,
ignoreExitCode?: boolean
} // Also supports all options of child_process::spawn
export function exec(filePath: string, parameters: array, options: $Options)
export function execNode(filePath: string, parameters: array, options: $Options)Explanation
options.local
options.local adds node executables in node_modules relative to
options.local.directory to PATH like in npm scripts.
options.local.prepend prioritizes local executables over ones already in PATH.
License
This project is licensed under the terms of MIT License, see the LICENSE file for more info