x3d-tidy 1.0.92 → 1.0.93
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/README.md +4 -0
- package/bin/x3d-tidy.js +2 -1
- package/package.json +1 -1
- package/src/convert.js +3 -1
package/README.md
CHANGED
package/bin/x3d-tidy.js
CHANGED
|
@@ -5,10 +5,11 @@ const os = require ("os")
|
|
|
5
5
|
const path = require ("path")
|
|
6
6
|
const { spawn } = require ("child_process")
|
|
7
7
|
const cwd = process .cwd ()
|
|
8
|
+
const cmd = os .platform () === "win32" ? "npm.cmd" : "npm"
|
|
8
9
|
|
|
9
10
|
process .chdir (path .resolve (__dirname, ".."))
|
|
10
11
|
|
|
11
|
-
const p = spawn (
|
|
12
|
+
const p = spawn (cmd, ["start", "--silent", "--", "--cwd", cwd, ... process .argv .slice (2)])
|
|
12
13
|
|
|
13
14
|
p .stdout .pipe (process .stdout)
|
|
14
15
|
p .stderr .pipe (process .stderr)
|
package/package.json
CHANGED
package/src/convert.js
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
const
|
|
4
4
|
X3D = require ("x_ite"),
|
|
5
|
-
infer = require ("./infer"),
|
|
6
5
|
pkg = require ("../package.json"),
|
|
6
|
+
infer = require ("./infer"),
|
|
7
7
|
metadata = require ("./metadata"),
|
|
8
8
|
electron = require ("electron"),
|
|
9
9
|
yargs = require ("yargs"),
|
|
@@ -43,6 +43,8 @@ async function convert (argv)
|
|
|
43
43
|
.scriptName ("x3d-tidy")
|
|
44
44
|
.usage ("$0 args")
|
|
45
45
|
.command ("x3d-tidy", "X3D converter, beautifier and minimizer")
|
|
46
|
+
.version (pkg .version)
|
|
47
|
+
.alias ("v", "version")
|
|
46
48
|
.fail ((msg, error, yargs) =>
|
|
47
49
|
{
|
|
48
50
|
console .error (msg)
|