@done-coding/cli-extract 0.0.1-alpha.0 → 0.0.2-alpha.0
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/es/cli.mjs +2 -2
- package/es/{index-6ac50ab8.js → index-daa98153.js} +12 -12
- package/es/index.mjs +2 -2
- package/package.json +4 -6
- package/types/injectInfo.json.d.ts +1 -1
package/es/cli.mjs
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import
|
|
3
|
-
import { hideBin as
|
|
4
|
-
import s from "
|
|
2
|
+
import c from "yargs";
|
|
3
|
+
import { hideBin as m } from "yargs/helpers";
|
|
4
|
+
import { log as s } from "@done-coding/cli-utils";
|
|
5
5
|
const i = async (o) => {
|
|
6
6
|
console.log(o);
|
|
7
7
|
}, n = {
|
|
8
|
-
version: "0.0.
|
|
8
|
+
version: "0.0.2-alpha.0",
|
|
9
9
|
name: "@done-coding/cli-extract",
|
|
10
10
|
description: "信息提取命令行工具",
|
|
11
11
|
cliConfig: {
|
|
12
12
|
namespaceDir: ".done-coding",
|
|
13
13
|
moduleName: "extract"
|
|
14
14
|
}
|
|
15
|
-
},
|
|
15
|
+
}, l = () => ({
|
|
16
16
|
xx: {
|
|
17
17
|
alias: "x",
|
|
18
18
|
describe: "模版测试",
|
|
@@ -20,17 +20,17 @@ const i = async (o) => {
|
|
|
20
20
|
demandOption: !0
|
|
21
21
|
}
|
|
22
22
|
}), a = n.cliConfig.moduleName, d = (o, e) => {
|
|
23
|
-
|
|
24
|
-
}, p = n.description, g = `Usage: $0 ${a} [options]`,
|
|
25
|
-
const
|
|
26
|
-
return o.strict().usage(e).help("help").version(n.version).alias("v", "version").alias("h", "help").options(
|
|
27
|
-
},
|
|
23
|
+
o ? s.error(o) : s.error(e.message), process.exit(1);
|
|
24
|
+
}, p = n.description, g = `Usage: $0 ${a} [options]`, u = "Usage: $0 [options]", r = (o, e) => {
|
|
25
|
+
const t = l();
|
|
26
|
+
return o.strict().usage(e).help("help").version(n.version).alias("v", "version").alias("h", "help").options(t).fail(d).argv;
|
|
27
|
+
}, f = (o) => r(o, g), C = {
|
|
28
28
|
command: a,
|
|
29
29
|
describe: p,
|
|
30
|
-
builder:
|
|
30
|
+
builder: f,
|
|
31
31
|
handler: i
|
|
32
32
|
}, b = async () => {
|
|
33
|
-
const o =
|
|
33
|
+
const o = c(m(process.argv)), e = await r(o, u);
|
|
34
34
|
return i(e);
|
|
35
35
|
};
|
|
36
36
|
export {
|
package/es/index.mjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { a as e, h as i } from "./index-
|
|
2
|
+
import { a as e, h as i } from "./index-daa98153.js";
|
|
3
3
|
import "yargs";
|
|
4
4
|
import "yargs/helpers";
|
|
5
|
-
import "
|
|
5
|
+
import "@done-coding/cli-utils";
|
|
6
6
|
export {
|
|
7
7
|
e as command,
|
|
8
8
|
i as handler
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@done-coding/cli-extract",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.2-alpha.0",
|
|
4
4
|
"description": "信息提取命令行工具",
|
|
5
5
|
"private": false,
|
|
6
6
|
"module": "es/index.mjs",
|
|
@@ -41,9 +41,8 @@
|
|
|
41
41
|
"license": "MIT",
|
|
42
42
|
"sideEffects": false,
|
|
43
43
|
"devDependencies": {
|
|
44
|
-
"@done-coding/cli-inject": "^0.4.
|
|
44
|
+
"@done-coding/cli-inject": "^0.4.7-alpha.0",
|
|
45
45
|
"@types/node": "^16.0.0",
|
|
46
|
-
"@types/prompts": "^2.4.6",
|
|
47
46
|
"@types/yargs": "^17.0.28",
|
|
48
47
|
"rimraf": "^6.0.1",
|
|
49
48
|
"typescript": "^5.2.2",
|
|
@@ -54,9 +53,8 @@
|
|
|
54
53
|
"node": ">=16.0.0"
|
|
55
54
|
},
|
|
56
55
|
"dependencies": {
|
|
57
|
-
"
|
|
58
|
-
"prompts": "^2.4.2",
|
|
56
|
+
"@done-coding/cli-utils": "^0.2.2-alpha.0",
|
|
59
57
|
"yargs": "^17.7.2"
|
|
60
58
|
},
|
|
61
|
-
"gitHead": "
|
|
59
|
+
"gitHead": "2e59e86ee192e023138e7475f4abbb5e7c42b29e"
|
|
62
60
|
}
|