Skip to content

Commit

Permalink
fix(run-npm-script): use cross-spawn
Browse files Browse the repository at this point in the history
  • Loading branch information
Simon Mollweide committed Apr 22, 2018
1 parent 2b43389 commit dddf087
Show file tree
Hide file tree
Showing 4 changed files with 109 additions and 21 deletions.
123 changes: 105 additions & 18 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@
"dependencies": {
"chalk": "2.4.0",
"commander": "2.15.1",
"cross-spawn": "6.0.5",
"glob": "7.1.2",
"string-length": "2.0.0"
},
Expand Down
2 changes: 1 addition & 1 deletion src/runNpmScript/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
/* eslint complexity: 0*/
/* eslint no-empty: 0*/
'use strict';
const { spawn } = require('child_process');
const spawn = require('cross-spawn');

/**
* @description run the given script in childProcess
Expand Down
4 changes: 2 additions & 2 deletions src/runNpmScript/index.spec.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/* global jest */
const { spawn } = require('child_process');
const spawn = require('cross-spawn');
const runNpmScript = require('./index');

jest.mock('child_process');
jest.mock('cross-spawn');

const options = {
scriptName: 'utils',
Expand Down

0 comments on commit dddf087

Please sign in to comment.