# exec-then

> Child process execute with promise, deferred

Latest version **1.3.1** (published 2015-02-16) · MIT license · 0 weekly downloads

## Install

```sh
npm install exec-then
pnpm add exec-then
yarn add exec-then
bun add exec-then
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.3.1 |
| Published | 2015-02-16 |
| First published | 2015-02-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 4 |
| Author | ragingwind |
| Maintainers | ragingwind |
| Keywords | exec-then, exec, promise, deferred, chile_process |

## Links

- npm: https://www.npmjs.com/package/exec-then
- Repository: https://github.com/ragingwind/exec-then
- Homepage: https://github.com/ragingwind/deferred-exec
- Issues: https://github.com/ragingwind/exec-then/issues
- npm.io page: https://npm.io/package/exec-then

## Dependencies (1)

- [q](https://npm.io/package/q.md) ^1.1.2

## Alternatives

- [promise-throttle](https://npm.io/package/promise-throttle.md) — 44.2K weekly downloads
- [@commercetools/sync-actions](https://npm.io/package/@commercetools/sync-actions.md) — 25.1K weekly downloads
- [cwait](https://npm.io/package/cwait.md) — 21.4K weekly downloads
- [@ledgerhq/hw-app-cosmos](https://npm.io/package/@ledgerhq/hw-app-cosmos.md) — 4.2K weekly downloads
- [@financial-times/o-loading](https://npm.io/package/@financial-times/o-loading.md) — 2.8K weekly downloads

## Recent versions

- 1.3.1 (latest) — 2015-02-16
- 1.3.0 — 2015-02-16
- 1.2.2 — 2015-02-16
- 1.2.0 — 2015-02-16
- 1.1.2 — 2015-02-16
- 1.1.1 — 2015-02-15
- 1.1.0 — 2015-02-15
- 1.0.1 — 2015-02-14

## README

#  [![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Dependency Status][daviddm-url]][daviddm-image]

> Child process execute with promise, deferred


## Install

```sh
$ npm install --save exec-then
```


## Usage

```js
var exec = require('exec-then');

exec('pwd').then(function(res) {
  assert(res.stdout.indexOf(path.resolve(__dirname, '../')) !== -1);
}, function(err) {
  console.log(err.toString());
  assert(false);
});

exec(['ls', '-al'], function(std, deferred) {
  if (std.stdout.indexOf('test') === -1) {
    return deferred.reject();
  }
  return true;
}).then(function(res) {
  if (res) {
    console.log('You have test file');
  }
}, function() {
  console.log('Where am I?');
});
```

## Options

`exec-node` using same options to [Child Process options](http://goo.gl/axu96) except to options below.

- `verbose`: show stdio/stderr message while child process is running. if verbose set true? `child_process.spawn` will be executed.

## License

MIT © [ragingwind](http://ragingwind.me)


[npm-url]: https://npmjs.org/package/exec-then
[npm-image]: https://badge.fury.io/js/exec-then.svg
[travis-url]: https://travis-ci.org/ragingwind/exec-then
[travis-image]: https://travis-ci.org/ragingwind/exec-then.svg?branch=master
[daviddm-url]: https://david-dm.org/ragingwind/exec-then.svg?theme=shields.io
[daviddm-image]: https://david-dm.org/ragingwind/exec-then

---
_Source: https://npm.io/package/exec-then · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
