chore(deps): update dependency execa to v10
This MR contains the following updates:
| Package | Type | Update | Change |
|---|---|---|---|
| execa | devDependencies | major | ^9.5.3 -> ^10.0.1 |
MR created with the help of gitlab-org/frontend/renovate-gitlab-bot
Release Notes
sindresorhus/execa (execa)
v10.0.1
v10.0.0
Breaking
-
The subprocess is now a normal promise, instead of a
ChildProcessinstance augmented with promise methods. All the methods and properties documented by Execa are unchanged. Node.js-specificChildProcessAPIs (such as.on(),.send(),.ref()and.unref()) must now be accessed through the newsubprocess.nodeChildProcessproperty. (#1255)ade74bf
const subprocess = execa('node', ['file.js']);
- subprocess.on('spawn', onSpawn);
+ subprocess.nodeChildProcess.on('spawn', onSpawn);- Removed
execaCommand()andexecaCommandSync(). Use the template string syntax instead, which splits on spaces. If the command is a dynamic string, split it withparseCommandString(). (#1244)3ced394
- await execaCommand('npm run build');
+ await execa`npm run build`;
- await execaCommand(commandString);
+ await execa`${parseCommandString(commandString)}`;- Removed the old undocumented
stdio: [..., 'ipc']syntax. Use theipc: trueoption instead. (#1245)dcf611c
- await execa('node', ['file.js'], {stdio: ['pipe', 'pipe', 'pipe', 'ipc']});
+ await execa('node', ['file.js'], {ipc: true});- When the
inputorinputFileoption is combined with an inheritedstdin(for examplestdio: 'inherit'), the explicit input is now used, instead of being ignored. To combine multiple inputs, pass an array likestdin: ['inherit', {string: 'input'}]. (#1232)3ed0544
Improvements
- Terminate the subprocess' descendant processes by using the
killDescendantsoption. This is useful when the subprocess spawns its own processes, such as when using theshelloption. (#1256)84fa0ec
await execa('npm', ['run', 'build'], {killDescendants: true, timeout: 5000});- Convert the subprocess to a web stream by using
subprocess.readableStream(),subprocess.writableStream()orsubprocess.transformStream(). (#1254)29d9cfc
await execa`npm run build`
.readableStream()
.pipeTo(writableWebStream);- The value returned by
subprocess.pipe()now exposes the destination subprocess' methods, so the piped output can be consumed directly: iterate over its output lines, convert it to a stream, or exchange IPC messages. (#1252)c31c94c
for await (const line of execa`npm run build`.pipe`sort`) {
console.log(line);
}- Use an additional file descriptor as input by wrapping its
stdiovalue as a{value, input: true}object. Direction-ambiguous values ('pipe','inherit', files and transforms) default to output on additional file descriptors. (#1246, #1249)487a3a49fbf5ba
const subprocess = execa({stdio: ['pipe', 'pipe', 'pipe', {value: 'pipe', input: true}]})`npm run scaffold`;
const writable = subprocess.writable({to: 'fd3'});- The transform generator function's
chunkargument is now typed based on the transform's mode, instead of always beingunknown:stringfor line transforms,Uint8Arrayfor binary transforms, andunknownin object mode. (#1247)0a7b4f8
Fixes
- Fixed fd-specific options (
verbose,maxBuffer, etc.) when theipcoption istrue:fd3andipcno longer target the same file descriptor. (#1241)b886883
v9.6.1
v9.6.0
- Update dependencies
d49104a
Configuration
- If you want to rebase/retry this MR, check this box
This MR has been generated by Renovate Bot.