@done-coding/cli-inject 0.3.0 → 0.3.1

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.
@@ -1,11 +1,11 @@
1
1
  #!/usr/bin/env node
2
2
  const n = {
3
- version: "0.3.0",
3
+ version: "0.3.1",
4
4
  name: "@done-coding/cli-inject",
5
5
  description: "信息注入命令行工具",
6
6
  cliConfig: {
7
7
  namespaceDir: ".done-coding",
8
- commandName: "inject"
8
+ moduleName: "inject"
9
9
  }
10
10
  };
11
11
  export {
package/es/main.mjs CHANGED
@@ -2,8 +2,8 @@
2
2
  import c from "yargs";
3
3
  import { hideBin as l } from "yargs/helpers";
4
4
  import { handler as i } from "./handler.mjs";
5
- import s from "chalk";
6
- import n from "./injectInfo.json.mjs";
5
+ import n from "chalk";
6
+ import s from "./injectInfo.json.mjs";
7
7
  const m = () => ({
8
8
  sourceJsonFilePath: {
9
9
  type: "string",
@@ -23,18 +23,18 @@ const m = () => ({
23
23
  describe: "注入信息文件路径",
24
24
  default: "./src/injectInfo.json"
25
25
  }
26
- }), t = n.cliConfig.commandName, d = (e, o) => {
27
- console.log(e ? s.red(e) : s.red(o.message)), process.exit(1);
28
- }, p = n.description, g = `Usage: $0 ${t} [options]`, f = "Usage: $0 [options]", a = (e, o) => {
29
- const r = m();
30
- return e.strict().usage(o).help("help").version(n.version).alias("v", "version").alias("h", "help").options(r).fail(d).argv;
31
- }, h = (e) => a(e, g), C = {
26
+ }), t = s.cliConfig.moduleName, d = (e, o) => {
27
+ console.log(e ? n.red(e) : n.red(o.message)), process.exit(1);
28
+ }, p = s.description, g = `Usage: $0 ${t} [options]`, f = "Usage: $0 [options]", r = (e, o) => {
29
+ const a = m();
30
+ return e.strict().usage(o).help("help").version(s.version).alias("v", "version").alias("h", "help").options(a).fail(d).argv;
31
+ }, u = (e) => r(e, g), C = {
32
32
  command: t,
33
33
  describe: p,
34
- builder: h,
34
+ builder: u,
35
35
  handler: i
36
36
  }, k = async () => {
37
- const e = c(l(process.argv)), o = await a(e, f);
37
+ const e = c(l(process.argv)), o = await r(e, f);
38
38
  return i(o);
39
39
  };
40
40
  export {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@done-coding/cli-inject",
3
- "version": "0.3.0",
3
+ "version": "0.3.1",
4
4
  "description": "信息注入命令行工具",
5
5
  "private": false,
6
6
  "module": "es/index.mjs",
@@ -61,5 +61,5 @@
61
61
  "prompts": "^2.4.2",
62
62
  "yargs": "^17.7.2"
63
63
  },
64
- "gitHead": "0e9dcf532b8abf7608d07f738348538fa9a9864d"
64
+ "gitHead": "d1dabd6e46a5e38793bba477449dd62aa4d9c4c1"
65
65
  }
@@ -1,10 +1,10 @@
1
1
  declare const _default: {
2
- "version": "0.3.0",
2
+ "version": "0.3.1",
3
3
  "name": "@done-coding/cli-inject",
4
4
  "description": "信息注入命令行工具",
5
5
  "cliConfig": {
6
6
  "namespaceDir": ".done-coding",
7
- "commandName": "inject"
7
+ "moduleName": "inject"
8
8
  }
9
9
  };
10
10