src/execute.js
function createSequencialCommandExecutor (commands, workingDir, envVars, watchMode, host) {
    const source = Observable.from([{
        cwd: workingDir,
        env: envVars,
        exitCode: 0
    }]);

    return commands.reduce((prev, command) =>
        createCommandExecutor(command, prev, watchMode, host), source);
}
function createSequencialCommandExecutor (commands, workingDir, envVars, watchMode, host) {
    const source = Observable.from([{
        cwd: workingDir,
        env: envVars,
        exitCode: 0
    }]);

    return commands.reduce((prev, command) =>
        createCommandExecutor(command, prev, watchMode, host), source);
}
function createSequencialCommandExecutor ( commands , workingDir , envVars , watchMode , host ) { const source = Observable . from ( [ { cwd : workingDir , env : envVars , exitCode : 0 } ] ) ; return commands . reduce ( ( prev , command ) => createCommandExecutor ( command , prev , watchMode , host ) , source ) ; }
Create an Observable that would execute a sequence of commands.

@param commands {string[]} A sequence of commands to execute
@param workingDir {string} Initial Working Directory
@param envVars {Object} Initial environment variables
@param watchMode {boolean} Whether to execute watchers or not
@param host {{spawn: Function, log: Function}} Mockable host environment (mimicking child_process.spawn() and console.log())
@returns Observable
Create an Observable that would execute a sequence of commands .