Use python3 instead of python on non-windows machines.
This commit is contained in:
parent
bb05a22c9e
commit
9ac4415eee
@ -11,3 +11,4 @@ install:
|
||||
|
||||
script:
|
||||
- npm run test
|
||||
- npm run build
|
||||
|
||||
@ -17,8 +17,8 @@
|
||||
"test": "mocha test",
|
||||
"coverage": "nyc mocha test",
|
||||
"codecov": "nyc --reporter=lcov mocha test && codecov",
|
||||
"build": "python tools/create_package.py",
|
||||
"update": "python tools/update_includes.py",
|
||||
"svg": "python tools/optimize_svg_files.py"
|
||||
"build": "node tools/run_python.js tools/create_package.py",
|
||||
"update": "node tools/run_python.js tools/update_includes.py",
|
||||
"svg": "node tools/run_python.js tools/optimize_svg_files.py"
|
||||
}
|
||||
}
|
||||
|
||||
8
tools/run_python.js
Normal file
8
tools/run_python.js
Normal file
@ -0,0 +1,8 @@
|
||||
let cp = require ('child_process');
|
||||
let pythonExecutable = 'python';
|
||||
if (process.platform != 'win32') {
|
||||
pythonExecutable = 'python3';
|
||||
}
|
||||
cp.spawnSync ('python', process.argv.slice (2), {
|
||||
stdio: "inherit"
|
||||
});
|
||||
Loading…
Reference in New Issue
Block a user