sindresorhus/execa (execa)
### [`v8.0.1`](https://togithub.com/sindresorhus/execa/releases/tag/v8.0.1)
[Compare Source](https://togithub.com/sindresorhus/execa/compare/v8.0.0...v8.0.1)
##### Fixes
- Fix and document support for the [`{encoding: 'buffer'}` option](https://togithub.com/sindresorhus/execa#encoding). It is the same as `{encoding: null}`, but preferred over it. ([#572](https://togithub.com/sindresorhus/execa/issues/572))
### [`v8.0.0`](https://togithub.com/sindresorhus/execa/releases/tag/v8.0.0)
[Compare Source](https://togithub.com/sindresorhus/execa/compare/v7.2.0...v8.0.0)
##### Breaking
- Require Node.js 16.7.0 and later ([#569](https://togithub.com/sindresorhus/execa/issues/569))
### [`v7.2.0`](https://togithub.com/sindresorhus/execa/releases/tag/v7.2.0)
[Compare Source](https://togithub.com/sindresorhus/execa/compare/v7.1.1...v7.2.0)
- Add `cwd` error property ([#565](https://togithub.com/sindresorhus/execa/issues/565)) [`f57fdec`](https://togithub.com/sindresorhus/execa/commit/f57fdec)
### [`v7.1.1`](https://togithub.com/sindresorhus/execa/releases/tag/v7.1.1)
[Compare Source](https://togithub.com/sindresorhus/execa/compare/v7.1.0...v7.1.1)
#### Features
- Improve error message when `` $.sync(options)`command` `` is used instead of [`` $(options).sync`command` ``](https://togithub.com/sindresorhus/execa#synccommand) ([#551](https://togithub.com/sindresorhus/execa/issues/551))
#### Bug fixes
- Fix argument concatenation when using [`` $`command argument${value}` ``](https://togithub.com/sindresorhus/execa#command) ([#553](https://togithub.com/sindresorhus/execa/issues/553))
- Fix default value of the [`stdin` option](https://togithub.com/sindresorhus/execa#stdin) when using [`` $`command` ``](https://togithub.com/sindresorhus/execa#command): it should be `inherit` ([#550](https://togithub.com/sindresorhus/execa/issues/550))
### [`v7.1.0`](https://togithub.com/sindresorhus/execa/releases/tag/v7.1.0)
[Compare Source](https://togithub.com/sindresorhus/execa/compare/v7.0.0...v7.1.0)
#### Features
- Add [`$` method](https://togithub.com/sindresorhus/execa#command) to write Node.js scripts like zx. For more information, please see [this blog post](https://medium.com/@ehmicky/shell-free-scripts-with-execa-7-885fb3b42f83), [this section](https://togithub.com/sindresorhus/execa#scripts-interface) and [this page](https://togithub.com/sindresorhus/execa/blob/main/docs/scripts.md). Thanks [@aaronccasanova](https://togithub.com/aaronccasanova) for this great feature!
```js
import {$} from 'execa';
const branch = await $`git branch --show-current`;
await $`dep deploy --branch=${branch}`;
```
- Add [`.pipeStdout()`](https://togithub.com/sindresorhus/execa#pipestdouttarget), [`.pipeStderr()`](https://togithub.com/sindresorhus/execa#pipestderrtarget) and [`.pipeAll()`](https://togithub.com/sindresorhus/execa#pipealltarget) methods to redirect `stdout`/`stderr` to a file, a stream or another process.
```js
// Similar to `echo unicorns > stdout.txt` in Bash
await execa('echo', ['unicorns']).pipeStdout('stdout.txt');
// Similar to `echo unicorns 2> stdout.txt` in Bash
await execa('echo', ['unicorns']).pipeStderr('stderr.txt');
// Similar to `echo unicorns &> stdout.txt` in Bash
await execa('echo', ['unicorns'], {all: true}).pipeAll('all.txt');
```
- Add [`inputFile` option](https://togithub.com/sindresorhus/execa#inputfile) to use a file as `stdin`.
```js
// Similar to `cat < stdin.txt` in Bash
const {stdout} = await execa('cat', {inputFile: 'stdin.txt'});
console.log(stdout);
//=> 'unicorns'
```
- Add [`verbose` option](https://togithub.com/sindresorhus/execa#verbose) to print each command on `stderr` before executing it. This can also be enabled by setting the `NODE_DEBUG=execa` environment variable in the current process.
> node file.js
unicorns
rainbows
> NODE_DEBUG=execa node file.js
[16:50:03.305] echo unicorns
unicorns
[16:50:03.308] echo rainbows
rainbows
Configuration
📅 Schedule: Branch creation - "after 10pm,before 5:00am" (UTC), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
[ ] If you want to rebase/retry this PR, check this box
This PR has been generated by Mend Renovate. View repository job log here.
This PR contains the following updates:
^7.0.0
->^8.0.0
Release Notes
sindresorhus/execa (execa)
### [`v8.0.1`](https://togithub.com/sindresorhus/execa/releases/tag/v8.0.1) [Compare Source](https://togithub.com/sindresorhus/execa/compare/v8.0.0...v8.0.1) ##### Fixes - Fix and document support for the [`{encoding: 'buffer'}` option](https://togithub.com/sindresorhus/execa#encoding). It is the same as `{encoding: null}`, but preferred over it. ([#572](https://togithub.com/sindresorhus/execa/issues/572)) ### [`v8.0.0`](https://togithub.com/sindresorhus/execa/releases/tag/v8.0.0) [Compare Source](https://togithub.com/sindresorhus/execa/compare/v7.2.0...v8.0.0) ##### Breaking - Require Node.js 16.7.0 and later ([#569](https://togithub.com/sindresorhus/execa/issues/569)) ### [`v7.2.0`](https://togithub.com/sindresorhus/execa/releases/tag/v7.2.0) [Compare Source](https://togithub.com/sindresorhus/execa/compare/v7.1.1...v7.2.0) - Add `cwd` error property ([#565](https://togithub.com/sindresorhus/execa/issues/565)) [`f57fdec`](https://togithub.com/sindresorhus/execa/commit/f57fdec) ### [`v7.1.1`](https://togithub.com/sindresorhus/execa/releases/tag/v7.1.1) [Compare Source](https://togithub.com/sindresorhus/execa/compare/v7.1.0...v7.1.1) #### Features - Improve error message when `` $.sync(options)`command` `` is used instead of [`` $(options).sync`command` ``](https://togithub.com/sindresorhus/execa#synccommand) ([#551](https://togithub.com/sindresorhus/execa/issues/551)) #### Bug fixes - Fix argument concatenation when using [`` $`command argument${value}` ``](https://togithub.com/sindresorhus/execa#command) ([#553](https://togithub.com/sindresorhus/execa/issues/553)) - Fix default value of the [`stdin` option](https://togithub.com/sindresorhus/execa#stdin) when using [`` $`command` ``](https://togithub.com/sindresorhus/execa#command): it should be `inherit` ([#550](https://togithub.com/sindresorhus/execa/issues/550)) ### [`v7.1.0`](https://togithub.com/sindresorhus/execa/releases/tag/v7.1.0) [Compare Source](https://togithub.com/sindresorhus/execa/compare/v7.0.0...v7.1.0) #### Features - Add [`$` method](https://togithub.com/sindresorhus/execa#command) to write Node.js scripts like zx. For more information, please see [this blog post](https://medium.com/@ehmicky/shell-free-scripts-with-execa-7-885fb3b42f83), [this section](https://togithub.com/sindresorhus/execa#scripts-interface) and [this page](https://togithub.com/sindresorhus/execa/blob/main/docs/scripts.md). Thanks [@aaronccasanova](https://togithub.com/aaronccasanova) for this great feature! ```js import {$} from 'execa'; const branch = await $`git branch --show-current`; await $`dep deploy --branch=${branch}`; ``` - Add [`.pipeStdout()`](https://togithub.com/sindresorhus/execa#pipestdouttarget), [`.pipeStderr()`](https://togithub.com/sindresorhus/execa#pipestderrtarget) and [`.pipeAll()`](https://togithub.com/sindresorhus/execa#pipealltarget) methods to redirect `stdout`/`stderr` to a file, a stream or another process. ```js // Similar to `echo unicorns > stdout.txt` in Bash await execa('echo', ['unicorns']).pipeStdout('stdout.txt'); // Similar to `echo unicorns 2> stdout.txt` in Bash await execa('echo', ['unicorns']).pipeStderr('stderr.txt'); // Similar to `echo unicorns &> stdout.txt` in Bash await execa('echo', ['unicorns'], {all: true}).pipeAll('all.txt'); ``` - Add [`inputFile` option](https://togithub.com/sindresorhus/execa#inputfile) to use a file as `stdin`. ```js // Similar to `cat < stdin.txt` in Bash const {stdout} = await execa('cat', {inputFile: 'stdin.txt'}); console.log(stdout); //=> 'unicorns' ``` - Add [`verbose` option](https://togithub.com/sindresorhus/execa#verbose) to print each command on `stderr` before executing it. This can also be enabled by setting the `NODE_DEBUG=execa` environment variable in the current process. > node file.js unicorns rainbows > NODE_DEBUG=execa node file.js [16:50:03.305] echo unicorns unicorns [16:50:03.308] echo rainbows rainbowsConfiguration
📅 Schedule: Branch creation - "after 10pm,before 5:00am" (UTC), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate. View repository job log here.