Skip to content

Commit f3b8853

Browse files
committed
Use execa.command() instead of execa()
1 parent 6234764 commit f3b8853

File tree

4 files changed

+31
-8
lines changed

4 files changed

+31
-8
lines changed

package-lock.json

Lines changed: 25 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@
5353
"dependencies": {
5454
"chalk": "^2.4.2",
5555
"core-js": "^3.1.2",
56-
"execa": "sindresorhus/execa#cf0e1642f0b27dbffbcbf75fecb0ac217a886c70",
56+
"execa": "sindresorhus/execa#6853316dd101a3a31060f1e4e4c69dbdea1be4d7",
5757
"fancy-log": "^1.3.3",
5858
"jest-validate": "^24.8.0",
5959
"keep-func-props": "^1.3.2",

src/exec.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,23 +13,23 @@ export const exec = function(input, opts) {
1313
return execCommand(input, optsA)
1414
}
1515

16-
// Fire the command with `execa()` in promise mode
16+
// Fire the command with `execa.command()` in promise mode
1717
export const execCommand = async function(input, opts) {
1818
printEcho({ input, opts })
1919

2020
try {
21-
return await execa(input, opts)
21+
return await execa.command(input, opts)
2222
} catch (error) {
2323
throwError(error)
2424
}
2525
}
2626

27-
// Fire the command with `execa()` in stream mode
27+
// Fire the command with `execa.command()` in stream mode
2828
export const streamCommand = function(input, opts) {
2929
printEcho({ input, opts })
3030

3131
try {
32-
return execa(input, opts)
32+
return execa.command(input, opts)
3333
} catch (error) {
3434
// At the moment, `execa` never throws synchronously.
3535
// This is just a safety catch in case it has a bug.

test/helpers/snapshot.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ const fireTask = async function({
5252
}) {
5353
const execaOptsA = getExecaOpts({ command, opts, buffer, read, execaOpts })
5454

55-
const { exitCode, stdout, stderr } = await execa(
55+
const { exitCode, stdout, stderr } = await execa.command(
5656
`gulp --gulpfile ${GULPFILES_DIR}/${method}.js ${task}`,
5757
execaOptsA,
5858
)

0 commit comments

Comments
 (0)