@done-coding/cli-template 0.3.0 → 0.4.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/handler.mjs CHANGED
@@ -1,213 +1,239 @@
1
1
  #!/usr/bin/env node
2
- import { OutputModeEnum as d } from "./utils/types.mjs";
3
- import { completeDefaultOptions as S } from "./utils/dealOptions.mjs";
2
+ import { OutputModeEnum as b } from "./utils/types.mjs";
3
+ import { completeDefaultOptions as k } from "./utils/dealOptions.mjs";
4
+ import { getConfigPath as N } from "./utils/config.mjs";
4
5
  import m from "node:path";
5
- import s from "node:fs";
6
- import e from "chalk";
7
- import x from "lodash.template";
8
- import N from "lodash.assign";
9
- import F from "prompts";
10
- import I from "./injectInfo.json.mjs";
11
- const b = ({
12
- filePath: l,
13
- dataInit: n,
14
- limitJson: u,
15
- filePathKey: c,
16
- dataInitKey: f,
17
- dealMarkdown: i = !1
6
+ import u from "node:fs";
7
+ import t from "chalk";
8
+ import F from "lodash.template";
9
+ import R from "lodash.assign";
10
+ import E from "prompts";
11
+ const h = ({
12
+ filePath: n,
13
+ dataInit: l,
14
+ limitJson: f,
15
+ filePathKey: s,
16
+ dataInitKey: g,
17
+ dealMarkdown: a = !1
18
18
  }) => {
19
- if (l) {
20
- if (u && !l.endsWith(".json"))
19
+ if (n) {
20
+ if (f && !n.endsWith(".json"))
21
21
  return console.log(
22
- e.red(`${c}必须是json文件,请检查文件后缀名`)
22
+ t.red(`${s}必须是json文件,请检查文件后缀名`)
23
23
  ), process.exit(1);
24
- const t = s.readFileSync(m.resolve(l), "utf-8");
25
- let r = t;
26
- return i && l.endsWith(".md") && (r = t.replace(
24
+ const o = u.readFileSync(m.resolve(n), "utf-8");
25
+ let c = o;
26
+ return a && n.endsWith(".md") && (c = o.replace(
27
27
  /^\s*```[a-zA-Z0-9]+\s*[\r\n]+([\s\S]+?)```\s*$/,
28
28
  "$1"
29
- )), u ? JSON.parse(r) : r;
29
+ )), f ? JSON.parse(c) : c;
30
30
  } else
31
- return n ? (console.log(
32
- e.green(`${c} 为空,将使用${f}作为数据`)
33
- ), u ? JSON.parse(n) : n) : (console.log(e.red(`${c}与${f}不能同时为空`)), process.exit(1));
34
- }, y = (l, n) => {
35
- if (!n)
36
- return console.log(e.red(`${l}模式下output不能为空`)), process.exit(1);
37
- }, D = (l, n) => {
38
- if (n && l === n)
39
- return console.log(e.red("output与input不能相同")), process.exit(1);
40
- }, R = (l, n) => {
41
- if (!n)
42
- return console.log(e.red(`${l}模式下input不能为空`)), process.exit(1);
43
- }, w = async (l, {
44
- rollbackDelFileAgree: n = !1
31
+ return l ? (console.log(
32
+ t.green(`${s} 为空,将使用${g}作为数据`)
33
+ ), f ? JSON.parse(l) : l) : (console.log(t.red(`${s}与${g}不能同时为空`)), process.exit(1));
34
+ }, S = (n, l) => {
35
+ if (!l)
36
+ return console.log(t.red(`${n}模式下output不能为空`)), process.exit(1);
37
+ }, D = (n, l) => {
38
+ if (l && n === l)
39
+ return console.log(t.red("output与input不能相同")), process.exit(1);
40
+ }, I = (n, l) => {
41
+ if (!l)
42
+ return console.log(t.red(`${n}模式下input不能为空`)), process.exit(1);
43
+ }, x = async (n, {
44
+ rollbackDelFileAgree: l = !1
45
45
  } = {}) => {
46
46
  const {
47
- env: u,
48
- input: c,
49
- inputData: f,
50
- output: i,
51
- mode: t,
52
- rollback: r,
53
- dealMarkdown: a,
54
- envData: p
55
- } = l;
56
- if (r)
57
- switch (t) {
58
- case d.REPLACE:
59
- case d.RETURN: {
60
- console.log(e.red(`${t}模式不支持回滚`));
47
+ env: f,
48
+ input: s,
49
+ inputData: g,
50
+ output: a,
51
+ mode: o,
52
+ rollback: c,
53
+ dealMarkdown: v,
54
+ envData: d
55
+ } = n;
56
+ if (c)
57
+ switch (o) {
58
+ case b.REPLACE:
59
+ case b.RETURN: {
60
+ console.log(t.red(`${o}模式不支持回滚`));
61
61
  return;
62
62
  }
63
63
  }
64
64
  console.log(
65
- e.blue(`开始处理模板
66
- mode: ${t}
67
- rollback: ${r}
65
+ t.blue(`开始处理模板
66
+ mode: ${o}
67
+ rollback: ${c}
68
68
  `)
69
69
  );
70
- const $ = b({
71
- filePath: c,
72
- dataInit: f,
70
+ const r = h({
71
+ filePath: s,
72
+ dataInit: g,
73
73
  limitJson: !1,
74
74
  filePathKey: "input",
75
75
  dataInitKey: "inputData",
76
- dealMarkdown: a
77
- }), k = x($), E = typeof p == "function" ? p() : p, g = k(E);
78
- switch (t) {
79
- case d.OVERWRITE: {
80
- y(t, i), D(i, c);
81
- const o = m.resolve(i);
82
- if (s.mkdirSync(m.dirname(o), { recursive: !0 }), s.existsSync(o)) {
83
- if (r)
84
- if (n || (await F({
76
+ dealMarkdown: v
77
+ }), p = F(r), $ = typeof d == "function" ? d() : d, i = p($);
78
+ switch (o) {
79
+ case b.OVERWRITE: {
80
+ S(o, a), D(a, s);
81
+ const e = m.resolve(a);
82
+ if (u.mkdirSync(m.dirname(e), { recursive: !0 }), u.existsSync(e)) {
83
+ if (c)
84
+ if (l || (await E({
85
85
  type: "confirm",
86
86
  name: "remove",
87
- message: `${t}模式下回滚将删除${o},是否继续?`
87
+ message: `${o}模式下回滚将删除${e},是否继续?`
88
88
  })).remove) {
89
- s.rmSync(o, { force: !0 }), console.log(e.green(`${t}模式下${o}已删除`));
89
+ u.rmSync(e, { force: !0 }), console.log(t.green(`${o}模式下${e}已删除`));
90
90
  return;
91
91
  } else {
92
- console.log(e.yellow(`${t}模式下${o}回滚取消`));
92
+ console.log(t.yellow(`${o}模式下${e}回滚取消`));
93
93
  return;
94
94
  }
95
- console.log(e.blue(`output:${o} 已存在,将覆盖`));
95
+ console.log(t.blue(`output:${e} 已存在,将覆盖`));
96
96
  } else {
97
- if (r) {
97
+ if (c) {
98
98
  console.log(
99
- e.yellow(`${t}模式下${o}不存在,无需回滚`)
99
+ t.yellow(`${o}模式下${e}不存在,无需回滚`)
100
100
  );
101
101
  return;
102
102
  }
103
- console.log(e.blue(`output:${o} 不存在,将创建`));
103
+ console.log(t.blue(`output:${e} 不存在,将创建`));
104
104
  }
105
- s.writeFileSync(o, g, "utf-8"), console.log(e.green(`模板处理完成,输出到 ${o}`));
105
+ u.writeFileSync(e, i, "utf-8"), console.log(t.green(`模板处理完成,输出到 ${e}`));
106
106
  break;
107
107
  }
108
- case d.APPEND: {
109
- y(t, i), D(i, c);
110
- const o = m.resolve(i);
111
- if (s.mkdirSync(m.dirname(o), { recursive: !0 }), s.existsSync(o)) {
112
- const v = s.readFileSync(o, "utf-8");
113
- if (r) {
114
- s.writeFileSync(
115
- o,
116
- v.replace(g, ""),
108
+ case b.APPEND: {
109
+ S(o, a), D(a, s);
110
+ const e = m.resolve(a);
111
+ if (u.mkdirSync(m.dirname(e), { recursive: !0 }), u.existsSync(e)) {
112
+ const y = u.readFileSync(e, "utf-8");
113
+ if (c) {
114
+ u.writeFileSync(
115
+ e,
116
+ y.replace(i, ""),
117
117
  "utf-8"
118
- ), console.log(e.green(`${t}模式下${o}回滚完成`));
118
+ ), console.log(t.green(`${o}模式下${e}回滚完成`));
119
119
  return;
120
120
  }
121
- const h = v + g;
122
- s.writeFileSync(o, h, "utf-8"), console.log(e.green(`模板处理完成,追加到 ${o}`));
121
+ const w = y + i;
122
+ u.writeFileSync(e, w, "utf-8"), console.log(t.green(`模板处理完成,追加到 ${e}`));
123
123
  } else {
124
- if (r) {
124
+ if (c) {
125
125
  console.log(
126
- e.yellow(`${t}模式下${o}不存在,无需回滚`)
126
+ t.yellow(`${o}模式下${e}不存在,无需回滚`)
127
127
  );
128
128
  return;
129
129
  }
130
- console.log(e.blue(`output:${o} 不存在,将创建`)), s.writeFileSync(o, g, "utf-8"), console.log(e.green(`模板处理完成,输出到 ${o}`));
130
+ console.log(t.blue(`output:${e} 不存在,将创建`)), u.writeFileSync(e, i, "utf-8"), console.log(t.green(`模板处理完成,输出到 ${e}`));
131
131
  }
132
132
  break;
133
133
  }
134
- case d.REPLACE: {
135
- if (i && console.log(e.yellow(`output ${i} 将被忽略`)), R(t, c), u && u === c)
136
- return console.log(e.red("env 与 input 不能相同")), process.exit(1);
137
- const o = m.resolve(c);
138
- s.mkdirSync(m.dirname(o), { recursive: !0 }), s.writeFileSync(o, g, "utf-8"), console.log(e.green(`模板处理完成,输出到 ${o}`));
134
+ case b.REPLACE: {
135
+ if (a && console.log(t.yellow(`output ${a} 将被忽略`)), I(o, s), f && f === s)
136
+ return console.log(t.red("env 与 input 不能相同")), process.exit(1);
137
+ const e = m.resolve(s);
138
+ u.mkdirSync(m.dirname(e), { recursive: !0 }), u.writeFileSync(e, i, "utf-8"), console.log(t.green(`模板处理完成,输出到 ${e}`));
139
139
  break;
140
140
  }
141
- case d.RETURN:
141
+ case b.RETURN:
142
142
  return console.log(
143
- e.green("模板处理完成,返回结果(函数调用才会拿到返回值)")
144
- ), g;
143
+ t.green("模板处理完成,返回结果(函数调用才会拿到返回值)")
144
+ ), i;
145
145
  default:
146
- return console.log(e.red(`mode ${t} 不支持`)), process.exit(1);
146
+ return console.log(t.red(`mode ${o} 不支持`)), process.exit(1);
147
147
  }
148
- return g;
148
+ return i;
149
149
  }, C = async ({
150
+ rootDir: n = process.cwd(),
150
151
  itemDefaultRollback: l = !1
151
- } = {}, n) => {
152
- let u;
153
- if (n)
154
- u = n;
152
+ } = {}, f) => {
153
+ let s;
154
+ if (f)
155
+ s = f;
155
156
  else {
156
- const { namespaceDir: t, moduleName: r } = I.cliConfig, a = m.resolve(t, `${r}.json`);
157
- if (!s.existsSync(a))
158
- return console.log(e.red(`配置文件${a}不存在`)), process.exit(1);
159
- const p = s.readFileSync(a, "utf-8");
160
- u = JSON.parse(p);
157
+ const r = N(n);
158
+ if (!r)
159
+ return console.log(t.red(`配置文件${r}不存在`)), process.exit(1);
160
+ const p = u.readFileSync(r, "utf-8");
161
+ s = JSON.parse(p);
161
162
  }
162
- const { list: c, globalEnvData: f } = u, i = c.map((t) => {
163
- const { rollback: r = l } = t, { envData: a, env: p, ...$ } = S(t);
164
- return p && console.log(e.yellow(`批量处理中 env:${p} 将被忽略,只读envData`)), {
165
- ...$,
166
- envData: N({}, f, a),
167
- rollback: r
163
+ const {
164
+ list: g,
165
+ globalEnvData: a = {},
166
+ collectEnvDataForm: o = []
167
+ } = s, c = {};
168
+ for (const r of o) {
169
+ let p, $, i;
170
+ typeof r == "string" ? (p = r, $ = r, i = void 0) : (p = r.key, $ = r.label, i = r.initial), c[p] = (await E({
171
+ type: "text",
172
+ name: p,
173
+ message: `请输入${$}`,
174
+ initial: i,
175
+ format: (e) => (e || "").trim(),
176
+ validate: (e) => e ? !0 : `${$}不能为空`
177
+ }))[p];
178
+ }
179
+ const v = g.map((r) => {
180
+ const { rollback: p = l } = r, {
181
+ envData: $,
182
+ env: i,
183
+ input: e,
184
+ output: y,
185
+ ...w
186
+ } = k(r);
187
+ return i && console.log(t.yellow(`批量处理中 env:${i} 将被忽略,只读envData`)), {
188
+ ...w,
189
+ env: i,
190
+ input: n && e ? m.resolve(n, e) : e,
191
+ output: n && y ? m.resolve(n, y) : y,
192
+ envData: R({}, a, c, $),
193
+ rollback: p
168
194
  };
169
- });
170
- return Promise.all(
171
- i.map(
172
- (t) => w(t, {
173
- rollbackDelFileAgree: !0
174
- })
175
- )
176
- );
177
- }, U = async (l) => {
195
+ }), d = [];
196
+ for (const r of v) {
197
+ const p = await x(r, {
198
+ rollbackDelFileAgree: !0
199
+ });
200
+ d.push(p);
201
+ }
202
+ return d;
203
+ }, U = async (n) => {
178
204
  const {
179
- envData: n,
180
- env: u,
181
- input: c,
182
- inputData: f,
183
- output: i,
184
- mode: t,
185
- rollback: r,
186
- dealMarkdown: a,
187
- batch: p
188
- } = S(l);
189
- if (p)
190
- return console.log(e.blue("开始批量处理")), C({
205
+ envData: l,
206
+ env: f,
207
+ input: s,
208
+ inputData: g,
209
+ output: a,
210
+ mode: o,
211
+ rollback: c,
212
+ dealMarkdown: v,
213
+ batch: d
214
+ } = k(n);
215
+ if (d)
216
+ return console.log(t.blue("开始批量处理")), C({
191
217
  // 回滚默认值 基于全局
192
- itemDefaultRollback: r
218
+ itemDefaultRollback: c
193
219
  });
194
- console.log(e.blue("开始单个处理"));
195
- const $ = b({
196
- filePath: u,
197
- dataInit: n,
220
+ console.log(t.blue("开始单个处理"));
221
+ const r = h({
222
+ filePath: f,
223
+ dataInit: l,
198
224
  limitJson: !0,
199
225
  filePathKey: "env",
200
226
  dataInitKey: "envData",
201
- dealMarkdown: a
227
+ dealMarkdown: v
202
228
  });
203
- return w({
204
- input: c,
205
- inputData: f,
206
- output: i,
207
- mode: t,
208
- rollback: r,
209
- dealMarkdown: a,
210
- envData: $
229
+ return x({
230
+ input: s,
231
+ inputData: g,
232
+ output: a,
233
+ mode: o,
234
+ rollback: c,
235
+ dealMarkdown: v,
236
+ envData: r
211
237
  });
212
238
  };
213
239
  export {
package/es/index.mjs CHANGED
@@ -1,9 +1,12 @@
1
1
  #!/usr/bin/env node
2
- import { handler as e } from "./handler.mjs";
3
- import { command as n } from "./main.mjs";
2
+ import { batchHandler as e, handler as t } from "./handler.mjs";
3
+ import { command as m } from "./main.mjs";
4
4
  import { OutputModeEnum as d } from "./utils/types.mjs";
5
+ import { getConfigPath as p } from "./utils/config.mjs";
5
6
  export {
6
7
  d as OutputModeEnum,
7
- n as command,
8
- e as handler
8
+ e as batchHandler,
9
+ m as command,
10
+ p as getConfigPath,
11
+ t as handler
9
12
  };
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  const e = {
3
- version: "0.3.0",
3
+ version: "0.4.0",
4
4
  name: "@done-coding/cli-template",
5
5
  description: "预编译命令行工具",
6
6
  cliConfig: {
package/es/main.mjs CHANGED
@@ -1,11 +1,13 @@
1
1
  #!/usr/bin/env node
2
2
  import d from "yargs";
3
3
  import { hideBin as m } from "yargs/helpers";
4
- import { OutputModeEnum as a } from "./utils/types.mjs";
5
- import { defaultOptions as t } from "./utils/dealOptions.mjs";
4
+ import { OutputModeEnum as t } from "./utils/types.mjs";
5
+ import { defaultOptions as a } from "./utils/dealOptions.mjs";
6
+ import i from "./injectInfo.json.mjs";
7
+ import "node:path";
8
+ import "node:fs";
6
9
  import { handler as n } from "./handler.mjs";
7
10
  import s from "chalk";
8
- import i from "./injectInfo.json.mjs";
9
11
  const p = () => ({
10
12
  env: {
11
13
  alias: "e",
@@ -32,12 +34,12 @@ const p = () => ({
32
34
  describe: "输出模式",
33
35
  type: "string",
34
36
  choices: [
35
- a.OVERWRITE,
36
- a.APPEND,
37
- a.REPLACE,
38
- a.RETURN
37
+ t.OVERWRITE,
38
+ t.APPEND,
39
+ t.REPLACE,
40
+ t.RETURN
39
41
  ],
40
- default: t.mode
42
+ default: a.mode
41
43
  },
42
44
  output: {
43
45
  alias: "o",
@@ -48,35 +50,35 @@ const p = () => ({
48
50
  alias: "r",
49
51
  describe: "是否回滚",
50
52
  type: "boolean",
51
- default: t.rollback
53
+ default: a.rollback
52
54
  },
53
55
  dealMarkdown: {
54
56
  alias: "d",
55
57
  describe: "(检测是markdown)是否处理(单个)代码块包裹",
56
58
  type: "boolean",
57
- default: t.dealMarkdown
59
+ default: a.dealMarkdown
58
60
  },
59
61
  batch: {
60
62
  alias: "b",
61
63
  describe: "是否批量处理",
62
64
  type: "boolean",
63
- default: t.batch
65
+ default: a.batch
64
66
  }
65
67
  }), r = i.cliConfig.moduleName, u = (e, o) => {
66
68
  console.log(e ? s.red(e) : s.red(o.message)), process.exit(1);
67
69
  }, b = i.description, g = `Usage: $0 ${r} [options]`, f = "Usage: $0 [options]", c = (e, o) => {
68
70
  const l = p();
69
71
  return e.strict().usage(o).help("help").version(i.version).alias("v", "version").alias("h", "help").options(l).fail(u).argv;
70
- }, h = (e) => c(e, g), D = {
72
+ }, h = (e) => c(e, g), U = {
71
73
  command: r,
72
74
  describe: b,
73
75
  builder: h,
74
76
  handler: n
75
- }, R = async () => {
77
+ }, w = async () => {
76
78
  const e = d(m(process.argv)), o = await c(e, f);
77
79
  return n(o);
78
80
  };
79
81
  export {
80
- D as command,
81
- R as createCli
82
+ U as command,
83
+ w as createCli
82
84
  };
@@ -0,0 +1,14 @@
1
+ #!/usr/bin/env node
2
+ import i from "../injectInfo.json.mjs";
3
+ import r from "node:path";
4
+ import f from "node:fs";
5
+ const p = (o) => {
6
+ const { namespaceDir: t, moduleName: s } = i.cliConfig, e = [t, `${s}.json`];
7
+ o && e.unshift(o);
8
+ const n = r.resolve(...e);
9
+ if (f.existsSync(n))
10
+ return n;
11
+ };
12
+ export {
13
+ p as getConfigPath
14
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@done-coding/cli-template",
3
- "version": "0.3.0",
3
+ "version": "0.4.0",
4
4
  "description": "预编译命令行工具",
5
5
  "private": false,
6
6
  "module": "es/index.mjs",
@@ -41,12 +41,12 @@
41
41
  "license": "MIT",
42
42
  "sideEffects": false,
43
43
  "devDependencies": {
44
- "@done-coding/cli-inject": "^0.3.1",
44
+ "@done-coding/cli-inject": "^0.4.1",
45
45
  "@types/lodash.assign": "^4.2.9",
46
46
  "@types/lodash.get": "^4.4.9",
47
47
  "@types/lodash.set": "^4.3.9",
48
48
  "@types/lodash.template": "^4.5.3",
49
- "@types/node": "^20.0.0",
49
+ "@types/node": "^18.0.0",
50
50
  "@types/prompts": "^2.4.6",
51
51
  "@types/yargs": "^17.0.28",
52
52
  "rimraf": "^6.0.1",
@@ -55,7 +55,7 @@
55
55
  "vite-plugin-dts": "^3.6.0"
56
56
  },
57
57
  "engines": {
58
- "node": ">=16.0.0"
58
+ "node": ">=18.0.0"
59
59
  },
60
60
  "dependencies": {
61
61
  "chalk": "^5.3.0",
@@ -66,5 +66,5 @@
66
66
  "prompts": "^2.4.2",
67
67
  "yargs": "^17.7.2"
68
68
  },
69
- "gitHead": "d1dabd6e46a5e38793bba477449dd62aa4d9c4c1"
69
+ "gitHead": "1778df27cf625b5588b1de38d260cfed75e123f2"
70
70
  }
@@ -1,7 +1,9 @@
1
1
  import type { CompileTemplateConfig } from './utils';
2
2
  import { type Options } from './utils';
3
3
  import type { ArgumentsCamelCase } from "yargs";
4
- export declare const batchHandler: ({ itemDefaultRollback, }?: {
4
+ export declare const batchHandler: ({ rootDir, itemDefaultRollback, }?: {
5
+ /** 根目录 */
6
+ rootDir?: string | undefined;
5
7
  /** item默认回滚? */
6
8
  itemDefaultRollback?: boolean | undefined;
7
9
  }, paramsConfig?: CompileTemplateConfig) => Promise<(string | undefined)[]>;
package/types/index.d.ts CHANGED
@@ -1,3 +1,4 @@
1
- export { handler } from "./handler";
1
+ export { handler, batchHandler } from "./handler";
2
2
  export { command } from "./main";
3
3
  export * from './utils/types';
4
+ export * from './utils/config';
@@ -1,5 +1,5 @@
1
1
  declare const _default: {
2
- "version": "0.3.0",
2
+ "version": "0.4.0",
3
3
  "name": "@done-coding/cli-template",
4
4
  "description": "预编译命令行工具",
5
5
  "cliConfig": {
@@ -0,0 +1,2 @@
1
+ /** 获取配置文件路径 */
2
+ export declare const getConfigPath: (rootDir?: string) => string | undefined;
@@ -1,2 +1,3 @@
1
1
  export * from "./types";
2
2
  export * from "./dealOptions";
3
+ export * from "./config";
@@ -19,7 +19,7 @@ export interface Options {
19
19
  /** 模板数据 */
20
20
  inputData?: string;
21
21
  /** 输出文件相对路径 */
22
- output: string;
22
+ output?: string;
23
23
  /** 输出模式 @default OutputModeEnum.OVERWRITE */
24
24
  mode: OutputModeEnum;
25
25
  /** 是否回滚 @default false */
@@ -34,10 +34,21 @@ export type CompileTemplateConfigListItem = Omit<Options, "envData"> & {
34
34
  /** 已经解析为对象的envData */
35
35
  envData: Record<string, any>;
36
36
  };
37
+ /** 采集环境变量配置 */
38
+ export interface CollectFormItem {
39
+ /** 采集环境变量的key */
40
+ key: string;
41
+ /** 采集环境变量标签 */
42
+ label: string;
43
+ /** 采集环境变量初始值 */
44
+ initial?: string;
45
+ }
37
46
  /** 编译模板配置 */
38
47
  export interface CompileTemplateConfig {
39
48
  /** 全局环境变量 */
40
- globalEnvData: Record<string, any>;
49
+ globalEnvData?: Record<string, any>;
50
+ /** 采集环境变量表单配置 */
51
+ collectEnvDataForm?: (CollectFormItem | string)[];
41
52
  /** 配置列表 */
42
53
  list: CompileTemplateConfigListItem[];
43
54
  }