joshrtay / prosh

A promise shell.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

prosh

Build status Git tag NPM version Code style

A promise shell.

Installation

$ npm install prosh

Usage

import prosh from 'prosh'
import co from 'co'

co(function * () {
  yield prosh(`
    echo "hello world"
    echo "hello world"
    `)
})

API

prosh(command)

  • command - command string the same way you would write it in a shell

Returns: a promise the resolves {code, output, time}, where code is exit code, output is stdout and stderr and time is run time

License

MIT

About

A promise shell.


Languages

Language:JavaScript 80.7%Language:Makefile 19.3%