cross-spawn-cb 0.6.6 → 0.6.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.js +2 -0
- package/lib/polyfills.js +10 -1
- package/lib/spawnSyncCallback.js +1 -2
- package/package.json +16 -10
- package/lib/spawn-sync.js +0 -8
package/lib/index.js
CHANGED
package/lib/polyfills.js
CHANGED
|
@@ -7,4 +7,13 @@ var path = require('path');
|
|
|
7
7
|
if (!path.delimiter) path.delimiter = process.platform === 'win32' ? ';' : ':';
|
|
8
8
|
|
|
9
9
|
var cp = require('child_process');
|
|
10
|
-
if (!cp.spawnSync)
|
|
10
|
+
if (!cp.spawnSync) {
|
|
11
|
+
var spawnCallback = __dirname + '/spawnCallback.js'; // eslint-disable-line n/no-path-concat
|
|
12
|
+
|
|
13
|
+
var functionExec = null; // break dependencies
|
|
14
|
+
cp.spawnSync = function spawnSyncPolyfill(cmd, args, options) {
|
|
15
|
+
if (!functionExec) functionExec = require('function-exec-sync');
|
|
16
|
+
|
|
17
|
+
return functionExec({ callbacks: true }, spawnCallback, cmd, args, options || {});
|
|
18
|
+
};
|
|
19
|
+
}
|
package/lib/spawnSyncCallback.js
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
var assign = require('just-extend');
|
|
2
1
|
var constants = require('./constants');
|
|
3
2
|
|
|
4
3
|
var spawnSync = require('./cross-spawn').sync;
|
|
5
4
|
|
|
6
5
|
module.exports = function spawnSyncCallback(command, args, options) {
|
|
7
6
|
options = options || {};
|
|
8
|
-
var syncOptions = assign({}, options || {}, {
|
|
7
|
+
var syncOptions = Object.assign({}, options || {}, {
|
|
9
8
|
env: options.env || process.env,
|
|
10
9
|
stdio: 'pipe',
|
|
11
10
|
encoding: 'utf8',
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cross-spawn-cb",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.9",
|
|
4
4
|
"description": "Cross spawn with a completion callback",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"cross-spawn",
|
|
@@ -22,36 +22,42 @@
|
|
|
22
22
|
"format": "prettier --write .",
|
|
23
23
|
"lint": "eslint .",
|
|
24
24
|
"prepublishOnly": "npm run lint && depcheck",
|
|
25
|
-
"test": "mocha-compat test/spec/**/*.test.js",
|
|
25
|
+
"test": "mocha-compat test/spec/**/*.test.js --no-timeouts",
|
|
26
26
|
"test:engines": "nvu engines npm test"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
29
|
"buffer-v6-polyfill": "^1.0.5",
|
|
30
|
-
"core-js": "^3.24.
|
|
30
|
+
"core-js": "^3.24.1",
|
|
31
31
|
"cross-spawn": "^7.0.3",
|
|
32
|
-
"function-exec-sync": "^0.2.
|
|
33
|
-
"just-extend": "^6.0.1",
|
|
32
|
+
"function-exec-sync": "^0.2.5",
|
|
34
33
|
"next-tick": "^1.1.0",
|
|
35
34
|
"once": "^1.4.0"
|
|
36
35
|
},
|
|
37
36
|
"devDependencies": {
|
|
38
|
-
"@babel/preset-env": "^7.18.
|
|
37
|
+
"@babel/preset-env": "^7.18.10",
|
|
39
38
|
"@rollup/plugin-babel": "^5.3.1",
|
|
40
39
|
"@rollup/plugin-commonjs": "^22.0.1",
|
|
41
40
|
"@rollup/plugin-node-resolve": "^13.3.0",
|
|
42
|
-
"@typescript-eslint/parser": "^5.
|
|
41
|
+
"@typescript-eslint/parser": "^5.32.0",
|
|
42
|
+
"cr": "^0.1.0",
|
|
43
43
|
"depcheck": "^1.4.3",
|
|
44
|
-
"eslint": "^8.
|
|
44
|
+
"eslint": "^8.21.0",
|
|
45
45
|
"eslint-config-prettier": "^8.5.0",
|
|
46
46
|
"eslint-config-standard": "^17.0.0",
|
|
47
47
|
"eslint-plugin-import": "^2.26.0",
|
|
48
48
|
"eslint-plugin-promise": "^6.0.0",
|
|
49
|
+
"is-version": "^0.2.1",
|
|
50
|
+
"lodash.find": "^4.6.0",
|
|
51
|
+
"match-semver": "^0.1.1",
|
|
49
52
|
"mocha-compat": "^3.5.5",
|
|
53
|
+
"node-install-release": "^0.3.10",
|
|
54
|
+
"node-version-utils": "^0.5.4",
|
|
50
55
|
"prettier": "^2.7.1",
|
|
51
|
-
"rollup": "^2.77.
|
|
56
|
+
"rollup": "^2.77.2",
|
|
52
57
|
"rollup-plugin-babel": "^4.4.0",
|
|
53
58
|
"rollup-plugin-commonjs": "^10.1.0",
|
|
54
|
-
"rollup-plugin-node-externals": "^4.1.1"
|
|
59
|
+
"rollup-plugin-node-externals": "^4.1.1",
|
|
60
|
+
"semver": "^5.7.1"
|
|
55
61
|
},
|
|
56
62
|
"engines": {
|
|
57
63
|
"node": ">=0.8"
|
package/lib/spawn-sync.js
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
var spawnCallback = __dirname + '/spawnCallback.js';
|
|
2
|
-
|
|
3
|
-
var functionExec = null; // break dependencies
|
|
4
|
-
module.exports = function spawnSyncFallback(cmd, args, options) {
|
|
5
|
-
if (!functionExec) functionExec = require('function-exec-sync');
|
|
6
|
-
|
|
7
|
-
return functionExec({ callbacks: true }, spawnCallback, cmd, args, options || {});
|
|
8
|
-
};
|