@storm-software/workspace-tools 1.72.3 → 1.73.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.
- package/CHANGELOG.md +24 -0
- package/index.js +374 -156
- package/meta.json +1 -1
- package/package.json +2 -2
- package/src/base/index.js +366 -148
- package/src/executors/rolldown/executor.js +362 -144
- package/src/executors/tsup/executor.js +362 -144
- package/src/executors/tsup-browser/executor.js +362 -144
- package/src/executors/tsup-neutral/executor.js +362 -144
- package/src/executors/tsup-node/executor.js +362 -144
- package/src/executors/typia/executor.js +362 -144
- package/src/executors/unbuild/executor.js +362 -144
- package/src/generators/browser-library/generator.js +362 -144
- package/src/generators/config-schema/generator.js +356 -138
- package/src/generators/neutral-library/generator.js +362 -144
- package/src/generators/node-library/generator.js +362 -144
- package/src/generators/preset/files/.github/workflows/build-release.yml.template +1 -1
- package/src/generators/preset/generator.js +356 -138
- package/src/generators/release-version/generator.js +358 -140
- package/src/utils/index.js +358 -140
package/src/base/index.js
CHANGED
|
@@ -46588,8 +46588,8 @@ var require_pax = __commonJS({
|
|
|
46588
46588
|
return len + s2;
|
|
46589
46589
|
}
|
|
46590
46590
|
};
|
|
46591
|
-
Pax.parse = (string, ex, g4) => new Pax(
|
|
46592
|
-
var
|
|
46591
|
+
Pax.parse = (string, ex, g4) => new Pax(merge3(parseKV(string), ex), g4);
|
|
46592
|
+
var merge3 = (a2, b6) => b6 ? Object.keys(a2).reduce((s2, k4) => (s2[k4] = a2[k4], s2), b6) : a2;
|
|
46593
46593
|
var parseKV = (string) => string.replace(/\n$/, "").split("\n").reduce(parseKVLine, /* @__PURE__ */ Object.create(null));
|
|
46594
46594
|
var parseKVLine = (set, line) => {
|
|
46595
46595
|
const n = parseInt(line, 10);
|
|
@@ -66808,64 +66808,6 @@ var require_cjs = __commonJS({
|
|
|
66808
66808
|
}
|
|
66809
66809
|
});
|
|
66810
66810
|
|
|
66811
|
-
// packages/config-tools/src/config-file/get-config-file.ts
|
|
66812
|
-
var import_deepmerge, getConfigFileByName, getConfigFile;
|
|
66813
|
-
var init_get_config_file = __esm({
|
|
66814
|
-
"packages/config-tools/src/config-file/get-config-file.ts"() {
|
|
66815
|
-
init_find_workspace_root();
|
|
66816
|
-
init_dist10();
|
|
66817
|
-
import_deepmerge = __toESM(require_cjs());
|
|
66818
|
-
getConfigFileByName = async (fileName, filePath) => {
|
|
66819
|
-
const workspacePath = filePath ? filePath : findWorkspaceRoot(filePath);
|
|
66820
|
-
return loadConfig({
|
|
66821
|
-
cwd: workspacePath,
|
|
66822
|
-
packageJson: true,
|
|
66823
|
-
name: fileName,
|
|
66824
|
-
envName: fileName?.toUpperCase(),
|
|
66825
|
-
jitiOptions: {
|
|
66826
|
-
debug: true,
|
|
66827
|
-
cache: process.env.STORM_CACHE ? process.env.STORM_CACHE_DIRECTORY : false
|
|
66828
|
-
}
|
|
66829
|
-
});
|
|
66830
|
-
};
|
|
66831
|
-
getConfigFile = async (filePath, additionalFileNames = []) => {
|
|
66832
|
-
const workspacePath = filePath ? filePath : findWorkspaceRoot(filePath);
|
|
66833
|
-
let { config, configFile } = await loadConfig({
|
|
66834
|
-
cwd: workspacePath,
|
|
66835
|
-
name: "storm"
|
|
66836
|
-
});
|
|
66837
|
-
if (additionalFileNames && additionalFileNames.length > 0) {
|
|
66838
|
-
const results = await Promise.all(
|
|
66839
|
-
additionalFileNames.map(
|
|
66840
|
-
(fileName) => loadConfig({
|
|
66841
|
-
cwd: workspacePath,
|
|
66842
|
-
name: fileName
|
|
66843
|
-
})
|
|
66844
|
-
)
|
|
66845
|
-
);
|
|
66846
|
-
for (const result of results) {
|
|
66847
|
-
if (result) {
|
|
66848
|
-
config = (0, import_deepmerge.default)(config ?? {}, result.config ?? {});
|
|
66849
|
-
}
|
|
66850
|
-
}
|
|
66851
|
-
}
|
|
66852
|
-
if (!config) {
|
|
66853
|
-
return void 0;
|
|
66854
|
-
}
|
|
66855
|
-
config.configFile = configFile;
|
|
66856
|
-
config.runtimeVersion = "0.0.1";
|
|
66857
|
-
return config;
|
|
66858
|
-
};
|
|
66859
|
-
}
|
|
66860
|
-
});
|
|
66861
|
-
|
|
66862
|
-
// packages/config-tools/src/config-file/index.ts
|
|
66863
|
-
var init_config_file = __esm({
|
|
66864
|
-
"packages/config-tools/src/config-file/index.ts"() {
|
|
66865
|
-
init_get_config_file();
|
|
66866
|
-
}
|
|
66867
|
-
});
|
|
66868
|
-
|
|
66869
66811
|
// node_modules/.pnpm/zod@3.22.4/node_modules/zod/lib/index.mjs
|
|
66870
66812
|
function setErrorMap(map) {
|
|
66871
66813
|
overrideErrorMap = map;
|
|
@@ -70600,23 +70542,71 @@ var init_lib = __esm({
|
|
|
70600
70542
|
});
|
|
70601
70543
|
|
|
70602
70544
|
// packages/config/src/schema.ts
|
|
70603
|
-
var ColorConfigSchema, StormConfigSchema;
|
|
70545
|
+
var DarkColorSchema, LightColorSchema, PrimaryColorSchema, SecondaryColorSchema, TertiaryColorSchema, AccentColorSchema, SuccessColorSchema, InfoColorSchema, WarningColorSchema, ErrorColorSchema, FatalColorSchema, DarkThemeColorConfigSchema, LightThemeColorConfigSchema, MultiThemeColorConfigSchema, SingleThemeColorConfigSchema, ColorConfigSchema, ColorConfigMapSchema, StormConfigSchema;
|
|
70604
70546
|
var init_schema = __esm({
|
|
70605
70547
|
"packages/config/src/schema.ts"() {
|
|
70606
70548
|
init_lib();
|
|
70607
|
-
|
|
70608
|
-
|
|
70609
|
-
|
|
70610
|
-
|
|
70611
|
-
|
|
70612
|
-
|
|
70613
|
-
|
|
70614
|
-
|
|
70615
|
-
|
|
70616
|
-
|
|
70617
|
-
|
|
70618
|
-
|
|
70619
|
-
|
|
70549
|
+
DarkColorSchema = z2.string().trim().toLowerCase().regex(/^#([0-9a-f]{3}){1,2}$/i).length(7).default("#1d232a").describe("The dark background color of the workspace");
|
|
70550
|
+
LightColorSchema = z2.string().trim().toLowerCase().regex(/^#([0-9a-f]{3}){1,2}$/i).length(7).default("#f4f4f5").describe("The light background color of the workspace");
|
|
70551
|
+
PrimaryColorSchema = z2.string().trim().toLowerCase().regex(/^#([0-9a-f]{3}){1,2}$/i).length(7).default("#1fb2a6").describe("The primary color of the workspace");
|
|
70552
|
+
SecondaryColorSchema = z2.string().trim().toLowerCase().regex(/^#([0-9a-f]{3}){1,2}$/i).length(7).default("#0ea5e9").describe("The secondary color of the workspace");
|
|
70553
|
+
TertiaryColorSchema = z2.string().trim().toLowerCase().regex(/^#([0-9a-f]{3}){1,2}$/i).length(7).default("#ec5990").describe("The tertiary color of the workspace");
|
|
70554
|
+
AccentColorSchema = z2.string().trim().toLowerCase().regex(/^#([0-9a-f]{3}){1,2}$/i).length(7).default("#6366f1").describe("The accent color of the workspace");
|
|
70555
|
+
SuccessColorSchema = z2.string().trim().toLowerCase().regex(/^#([0-9a-f]{3}){1,2}$/i).length(7).default("#087f5b").describe("The success color of the workspace");
|
|
70556
|
+
InfoColorSchema = z2.string().trim().toLowerCase().regex(/^#([0-9a-f]{3}){1,2}$/i).length(7).default("#0ea5e9").describe("The informational color of the workspace");
|
|
70557
|
+
WarningColorSchema = z2.string().trim().toLowerCase().regex(/^#([0-9a-f]{3}){1,2}$/i).length(7).default("#fcc419").describe("The warning color of the workspace");
|
|
70558
|
+
ErrorColorSchema = z2.string().trim().toLowerCase().regex(/^#([0-9a-f]{3}){1,2}$/i).length(7).default("#990000").describe("The error color of the workspace");
|
|
70559
|
+
FatalColorSchema = z2.string().trim().toLowerCase().regex(/^#([0-9a-f]{3}){1,2}$/i).length(7).default("#7d1a1a").describe("The fatal color of the workspace");
|
|
70560
|
+
DarkThemeColorConfigSchema = z2.object({
|
|
70561
|
+
foreground: LightColorSchema,
|
|
70562
|
+
background: DarkColorSchema,
|
|
70563
|
+
primary: PrimaryColorSchema,
|
|
70564
|
+
secondary: SecondaryColorSchema,
|
|
70565
|
+
tertiary: TertiaryColorSchema,
|
|
70566
|
+
accent: AccentColorSchema,
|
|
70567
|
+
success: SuccessColorSchema,
|
|
70568
|
+
info: InfoColorSchema,
|
|
70569
|
+
warning: WarningColorSchema,
|
|
70570
|
+
error: ErrorColorSchema,
|
|
70571
|
+
fatal: FatalColorSchema
|
|
70572
|
+
});
|
|
70573
|
+
LightThemeColorConfigSchema = z2.object({
|
|
70574
|
+
foreground: DarkColorSchema,
|
|
70575
|
+
background: LightColorSchema,
|
|
70576
|
+
primary: PrimaryColorSchema,
|
|
70577
|
+
secondary: SecondaryColorSchema,
|
|
70578
|
+
tertiary: TertiaryColorSchema,
|
|
70579
|
+
accent: AccentColorSchema,
|
|
70580
|
+
success: SuccessColorSchema,
|
|
70581
|
+
info: InfoColorSchema,
|
|
70582
|
+
warning: WarningColorSchema,
|
|
70583
|
+
error: ErrorColorSchema,
|
|
70584
|
+
fatal: FatalColorSchema
|
|
70585
|
+
});
|
|
70586
|
+
MultiThemeColorConfigSchema = z2.object({
|
|
70587
|
+
dark: DarkThemeColorConfigSchema,
|
|
70588
|
+
light: LightThemeColorConfigSchema
|
|
70589
|
+
});
|
|
70590
|
+
SingleThemeColorConfigSchema = z2.object({
|
|
70591
|
+
dark: DarkColorSchema,
|
|
70592
|
+
light: LightColorSchema,
|
|
70593
|
+
primary: PrimaryColorSchema,
|
|
70594
|
+
secondary: SecondaryColorSchema,
|
|
70595
|
+
tertiary: TertiaryColorSchema,
|
|
70596
|
+
accent: AccentColorSchema,
|
|
70597
|
+
success: SuccessColorSchema,
|
|
70598
|
+
info: InfoColorSchema,
|
|
70599
|
+
warning: WarningColorSchema,
|
|
70600
|
+
error: ErrorColorSchema,
|
|
70601
|
+
fatal: FatalColorSchema
|
|
70602
|
+
});
|
|
70603
|
+
ColorConfigSchema = SingleThemeColorConfigSchema.or(
|
|
70604
|
+
MultiThemeColorConfigSchema
|
|
70605
|
+
).describe("Colors used for various workspace elements");
|
|
70606
|
+
ColorConfigMapSchema = z2.union([
|
|
70607
|
+
z2.object({ "base": ColorConfigSchema }),
|
|
70608
|
+
z2.record(z2.string(), ColorConfigSchema)
|
|
70609
|
+
]);
|
|
70620
70610
|
StormConfigSchema = z2.object({
|
|
70621
70611
|
extends: z2.string().trim().optional().describe(
|
|
70622
70612
|
"The path to a base JSON file to use as a configuration preset file"
|
|
@@ -70667,7 +70657,7 @@ var init_schema = __esm({
|
|
|
70667
70657
|
configFile: z2.string().trim().nullable().default(null).describe(
|
|
70668
70658
|
"The filepath of the Storm config. When this field is null, no config file was found in the current workspace."
|
|
70669
70659
|
),
|
|
70670
|
-
colors: ColorConfigSchema.describe(
|
|
70660
|
+
colors: ColorConfigSchema.or(ColorConfigMapSchema).describe(
|
|
70671
70661
|
"Storm theme config values used for styling various package elements"
|
|
70672
70662
|
),
|
|
70673
70663
|
extensions: z2.record(z2.any()).optional().default({}).describe("Configuration of each used extension")
|
|
@@ -70678,8 +70668,22 @@ var init_schema = __esm({
|
|
|
70678
70668
|
});
|
|
70679
70669
|
|
|
70680
70670
|
// packages/config/src/types.ts
|
|
70671
|
+
var COLOR_KEYS;
|
|
70681
70672
|
var init_types = __esm({
|
|
70682
70673
|
"packages/config/src/types.ts"() {
|
|
70674
|
+
COLOR_KEYS = [
|
|
70675
|
+
"dark",
|
|
70676
|
+
"light",
|
|
70677
|
+
"primary",
|
|
70678
|
+
"secondary",
|
|
70679
|
+
"tertiary",
|
|
70680
|
+
"accent",
|
|
70681
|
+
"success",
|
|
70682
|
+
"info",
|
|
70683
|
+
"warning",
|
|
70684
|
+
"error",
|
|
70685
|
+
"fatal"
|
|
70686
|
+
];
|
|
70683
70687
|
}
|
|
70684
70688
|
});
|
|
70685
70689
|
|
|
@@ -72451,14 +72455,16 @@ var init_chalk = __esm({
|
|
|
72451
72455
|
});
|
|
72452
72456
|
|
|
72453
72457
|
// packages/config-tools/src/utilities/logger.ts
|
|
72454
|
-
var getLogFn, writeFatal, writeError, writeWarning, writeInfo, writeSuccess, writeDebug, writeTrace, writeSystem, getStopwatch;
|
|
72458
|
+
var getLogFn, writeFatal, writeError, writeWarning, writeInfo, writeSuccess, writeDebug, writeTrace, writeSystem, getStopwatch, formatLogMessage, _isFunction;
|
|
72455
72459
|
var init_logger = __esm({
|
|
72456
72460
|
"packages/config-tools/src/utilities/logger.ts"() {
|
|
72457
72461
|
init_types2();
|
|
72458
72462
|
init_get_log_level();
|
|
72459
72463
|
init_chalk();
|
|
72464
|
+
init_get_default_config();
|
|
72460
72465
|
getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
72461
72466
|
let _chalk = getChalk();
|
|
72467
|
+
const colors = !config.colors?.dark && !config.colors?.["base"] && !config.colors?.["base"]?.dark ? DEFAULT_COLOR_CONFIG : config.colors?.dark && typeof config.colors.dark === "string" ? config.colors : config.colors?.["base"]?.dark && typeof config.colors["base"].dark === "string" ? config.colors["base"].dark : config.colors?.["base"] ? config.colors?.["base"] : DEFAULT_COLOR_CONFIG;
|
|
72462
72468
|
const configLogLevel = config.logLevel ?? process.env?.STORM_LOG_LEVEL ?? LogLevelLabel.INFO;
|
|
72463
72469
|
if (typeof logLevel === "number" && (logLevel >= getLogLevel(configLogLevel) || logLevel <= LogLevel.SILENT) || typeof logLevel === "string" && getLogLevel(logLevel) >= getLogLevel(configLogLevel)) {
|
|
72464
72470
|
return (_6) => {
|
|
@@ -72468,9 +72474,9 @@ var init_logger = __esm({
|
|
|
72468
72474
|
return (message) => {
|
|
72469
72475
|
console.error(
|
|
72470
72476
|
`
|
|
72471
|
-
${_chalk.bold.hex(
|
|
72472
|
-
|
|
72473
|
-
)(message)}
|
|
72477
|
+
${_chalk.bold.hex(colors.error ?? "#f85149")(">")} ${_chalk.bold.bgHex(colors.fatal ?? "#b62324").whiteBright(
|
|
72478
|
+
" \u{1F480} Fatal "
|
|
72479
|
+
)} ${_chalk.hex(colors.error ?? "#f85149")(formatLogMessage(message))}
|
|
72474
72480
|
|
|
72475
72481
|
`
|
|
72476
72482
|
);
|
|
@@ -72480,9 +72486,9 @@ ${_chalk.bold.hex(config?.colors?.error ? config.colors.error : "#7d1a1a")(">")}
|
|
|
72480
72486
|
return (message) => {
|
|
72481
72487
|
console.error(
|
|
72482
72488
|
`
|
|
72483
|
-
${_chalk.bold.hex(
|
|
72484
|
-
|
|
72485
|
-
)(message)}
|
|
72489
|
+
${_chalk.bold.hex(colors.error ?? "#f85149")(">")} ${_chalk.bold.bgHex(colors.error ?? "#f85149").whiteBright(
|
|
72490
|
+
" \u2718 Error "
|
|
72491
|
+
)} ${_chalk.hex(colors.error ?? "#f85149")(formatLogMessage(message))}
|
|
72486
72492
|
`
|
|
72487
72493
|
);
|
|
72488
72494
|
};
|
|
@@ -72491,9 +72497,9 @@ ${_chalk.bold.hex(config?.colors?.error ? config.colors.error : "#7d1a1a")(">")}
|
|
|
72491
72497
|
return (message) => {
|
|
72492
72498
|
console.warn(
|
|
72493
72499
|
`
|
|
72494
|
-
${_chalk.bold.hex(
|
|
72495
|
-
|
|
72496
|
-
)(message)}
|
|
72500
|
+
${_chalk.bold.hex(colors.warning ?? "#e3b341")("> ")} ${_chalk.bold.bgHex(colors.warning ?? "#e3b341").whiteBright(
|
|
72501
|
+
" \u26A0 Warn "
|
|
72502
|
+
)} ${_chalk.hex(colors.warning ?? "#e3b341")(formatLogMessage(message))}
|
|
72497
72503
|
`
|
|
72498
72504
|
);
|
|
72499
72505
|
};
|
|
@@ -72502,9 +72508,9 @@ ${_chalk.bold.hex(config?.colors?.warning ? config.colors.warning : "#fcc419")("
|
|
|
72502
72508
|
return (message) => {
|
|
72503
72509
|
console.info(
|
|
72504
72510
|
`
|
|
72505
|
-
${_chalk.bold.hex(
|
|
72506
|
-
|
|
72507
|
-
)(message)}
|
|
72511
|
+
${_chalk.bold.hex(colors.success ?? "#56d364")(">")} ${_chalk.bold.bgHex(colors.success ?? "#56d364").whiteBright(
|
|
72512
|
+
" \u2713 Success "
|
|
72513
|
+
)} ${_chalk.hex(colors.success ?? "#56d364")(formatLogMessage(message))}
|
|
72508
72514
|
`
|
|
72509
72515
|
);
|
|
72510
72516
|
};
|
|
@@ -72513,9 +72519,9 @@ ${_chalk.bold.hex(config?.colors?.success ? config.colors.success : "#087f5b")("
|
|
|
72513
72519
|
return (message) => {
|
|
72514
72520
|
console.info(
|
|
72515
72521
|
`
|
|
72516
|
-
${_chalk.bold.hex(
|
|
72517
|
-
|
|
72518
|
-
)(message)}
|
|
72522
|
+
${_chalk.bold.hex(colors.info ?? "#58a6ff")(">")} ${_chalk.bold.bgHex(colors.info ?? "#58a6ff").whiteBright(
|
|
72523
|
+
" \u2139 Info "
|
|
72524
|
+
)} ${_chalk.hex(colors.info ?? "#58a6ff")(formatLogMessage(message))}
|
|
72519
72525
|
`
|
|
72520
72526
|
);
|
|
72521
72527
|
};
|
|
@@ -72524,9 +72530,9 @@ ${_chalk.bold.hex(config?.colors?.info ? config.colors.info : "#0ea5e9")(">")} $
|
|
|
72524
72530
|
return (message) => {
|
|
72525
72531
|
console.debug(
|
|
72526
72532
|
`
|
|
72527
|
-
${_chalk.bold.hex(
|
|
72528
|
-
|
|
72529
|
-
)(message)}
|
|
72533
|
+
${_chalk.bold.hex(colors.primary ?? "#1fb2a6")(">")} ${_chalk.bold.bgHex(colors.primary ?? "#1fb2a6").whiteBright(
|
|
72534
|
+
" \u{1F6E0} Debug "
|
|
72535
|
+
)} ${_chalk.hex(colors.primary ?? "#1fb2a6")(formatLogMessage(message))}
|
|
72530
72536
|
`
|
|
72531
72537
|
);
|
|
72532
72538
|
};
|
|
@@ -72534,9 +72540,9 @@ ${_chalk.bold.hex(config?.colors?.primary ? config.colors.primary : "#1fb2a6")("
|
|
|
72534
72540
|
return (message) => {
|
|
72535
72541
|
console.log(
|
|
72536
72542
|
`
|
|
72537
|
-
${_chalk.bold.hex(
|
|
72538
|
-
|
|
72539
|
-
)(message)}
|
|
72543
|
+
${_chalk.bold.hex(colors.primary ?? "#1fb2a6")(">")} ${_chalk.bold.bgHex(colors.primary ?? "#1fb2a6").whiteBright(
|
|
72544
|
+
" \u2709 System "
|
|
72545
|
+
)} ${_chalk.hex(colors.primary ?? "#1fb2a6")(formatLogMessage(message))}
|
|
72540
72546
|
`
|
|
72541
72547
|
);
|
|
72542
72548
|
};
|
|
@@ -72563,6 +72569,19 @@ ${_chalk.bold.hex(config?.colors?.primary ? config.colors.primary : "#1fb2a6")("
|
|
|
72563
72569
|
);
|
|
72564
72570
|
};
|
|
72565
72571
|
};
|
|
72572
|
+
formatLogMessage = (message, prefix = "-") => {
|
|
72573
|
+
return typeof message === "string" ? message : typeof message === "object" ? Object.keys(message).map(
|
|
72574
|
+
(key) => ` ${prefix} ${key} = ${_isFunction(message[key]) ? "<function>" : typeof message[key] === "object" ? `
|
|
72575
|
+
${formatLogMessage(message[key], `${prefix}-`)}` : message[key]}`
|
|
72576
|
+
).join("\n") : message;
|
|
72577
|
+
};
|
|
72578
|
+
_isFunction = (value2) => {
|
|
72579
|
+
try {
|
|
72580
|
+
return value2 instanceof Function || typeof value2 === "function" || !!(value2?.constructor && value2?.call && value2?.apply);
|
|
72581
|
+
} catch (e2) {
|
|
72582
|
+
return false;
|
|
72583
|
+
}
|
|
72584
|
+
};
|
|
72566
72585
|
}
|
|
72567
72586
|
});
|
|
72568
72587
|
|
|
@@ -72739,10 +72758,99 @@ var init_utilities = __esm({
|
|
|
72739
72758
|
}
|
|
72740
72759
|
});
|
|
72741
72760
|
|
|
72761
|
+
// packages/config-tools/src/config-file/get-config-file.ts
|
|
72762
|
+
var import_deepmerge, getConfigFileByName, getConfigFile;
|
|
72763
|
+
var init_get_config_file = __esm({
|
|
72764
|
+
"packages/config-tools/src/config-file/get-config-file.ts"() {
|
|
72765
|
+
init_find_workspace_root();
|
|
72766
|
+
init_dist10();
|
|
72767
|
+
import_deepmerge = __toESM(require_cjs());
|
|
72768
|
+
init_utilities();
|
|
72769
|
+
getConfigFileByName = async (fileName, filePath, options = {}) => {
|
|
72770
|
+
const workspacePath = filePath ? filePath : findWorkspaceRoot(filePath);
|
|
72771
|
+
let config = loadConfig({
|
|
72772
|
+
cwd: workspacePath,
|
|
72773
|
+
packageJson: true,
|
|
72774
|
+
name: fileName,
|
|
72775
|
+
envName: fileName?.toUpperCase(),
|
|
72776
|
+
jitiOptions: {
|
|
72777
|
+
debug: true,
|
|
72778
|
+
cache: process.env.STORM_CACHE ? process.env.STORM_CACHE_DIRECTORY : false
|
|
72779
|
+
},
|
|
72780
|
+
...options
|
|
72781
|
+
});
|
|
72782
|
+
if (!config || Object.keys(config).length === 0) {
|
|
72783
|
+
config = loadConfig({
|
|
72784
|
+
cwd: workspacePath,
|
|
72785
|
+
packageJson: true,
|
|
72786
|
+
name: fileName,
|
|
72787
|
+
envName: fileName?.toUpperCase(),
|
|
72788
|
+
jitiOptions: {
|
|
72789
|
+
debug: true,
|
|
72790
|
+
cache: process.env.STORM_CACHE ? process.env.STORM_CACHE_DIRECTORY : false
|
|
72791
|
+
},
|
|
72792
|
+
configFile: fileName,
|
|
72793
|
+
...options
|
|
72794
|
+
});
|
|
72795
|
+
}
|
|
72796
|
+
return config;
|
|
72797
|
+
};
|
|
72798
|
+
getConfigFile = async (filePath, additionalFileNames = []) => {
|
|
72799
|
+
const workspacePath = filePath ? filePath : findWorkspaceRoot(filePath);
|
|
72800
|
+
let { config, configFile } = await getConfigFileByName(
|
|
72801
|
+
"storm",
|
|
72802
|
+
workspacePath
|
|
72803
|
+
);
|
|
72804
|
+
if (config && Object.keys(config).length > 0) {
|
|
72805
|
+
writeTrace(
|
|
72806
|
+
`Found Storm configuration file "${configFile}" at "${workspacePath}"`,
|
|
72807
|
+
{
|
|
72808
|
+
logLevel: "all"
|
|
72809
|
+
}
|
|
72810
|
+
);
|
|
72811
|
+
writeTrace(config, { logLevel: "all" });
|
|
72812
|
+
}
|
|
72813
|
+
if (additionalFileNames && additionalFileNames.length > 0) {
|
|
72814
|
+
const results = await Promise.all(
|
|
72815
|
+
additionalFileNames.map(
|
|
72816
|
+
(fileName) => getConfigFileByName(fileName, workspacePath)
|
|
72817
|
+
)
|
|
72818
|
+
);
|
|
72819
|
+
for (const result of results) {
|
|
72820
|
+
if (result?.config && Object.keys(result.config).length > 0) {
|
|
72821
|
+
writeTrace(
|
|
72822
|
+
`Found additional configuration file "${result.configFile}" at "${workspacePath}"`,
|
|
72823
|
+
{
|
|
72824
|
+
logLevel: "all"
|
|
72825
|
+
}
|
|
72826
|
+
);
|
|
72827
|
+
writeTrace(result.config, { logLevel: "all" });
|
|
72828
|
+
config = (0, import_deepmerge.default)(config ?? {}, result.config ?? {});
|
|
72829
|
+
}
|
|
72830
|
+
}
|
|
72831
|
+
}
|
|
72832
|
+
if (!config) {
|
|
72833
|
+
return void 0;
|
|
72834
|
+
}
|
|
72835
|
+
config.configFile = configFile;
|
|
72836
|
+
config.runtimeVersion = "0.0.1";
|
|
72837
|
+
return config;
|
|
72838
|
+
};
|
|
72839
|
+
}
|
|
72840
|
+
});
|
|
72841
|
+
|
|
72842
|
+
// packages/config-tools/src/config-file/index.ts
|
|
72843
|
+
var init_config_file = __esm({
|
|
72844
|
+
"packages/config-tools/src/config-file/index.ts"() {
|
|
72845
|
+
init_get_config_file();
|
|
72846
|
+
}
|
|
72847
|
+
});
|
|
72848
|
+
|
|
72742
72849
|
// packages/config-tools/src/env/get-env.ts
|
|
72743
|
-
var getExtensionEnv, getConfigEnv;
|
|
72850
|
+
var getExtensionEnv, getConfigEnv, getThemeColorConfigEnv, getSingleThemeColorConfigEnv, getMultiThemeColorConfigEnv, getBaseThemeColorConfigEnv;
|
|
72744
72851
|
var init_get_env = __esm({
|
|
72745
72852
|
"packages/config-tools/src/env/get-env.ts"() {
|
|
72853
|
+
init_src();
|
|
72746
72854
|
init_utilities();
|
|
72747
72855
|
init_correct_paths();
|
|
72748
72856
|
getExtensionEnv = (extensionName) => {
|
|
@@ -72783,16 +72891,6 @@ var init_get_env = __esm({
|
|
|
72783
72891
|
ci: process.env[`${prefix}CI`] !== void 0 ? Boolean(
|
|
72784
72892
|
process.env[`${prefix}CI`] ?? process.env.CI ?? process.env.CONTINUOUS_INTEGRATION
|
|
72785
72893
|
) : void 0,
|
|
72786
|
-
colors: {
|
|
72787
|
-
primary: process.env[`${prefix}COLOR_PRIMARY`],
|
|
72788
|
-
dark: process.env[`${prefix}COLOR_DARK`],
|
|
72789
|
-
light: process.env[`${prefix}COLOR_LIGHT`],
|
|
72790
|
-
success: process.env[`${prefix}COLOR_SUCCESS`],
|
|
72791
|
-
info: process.env[`${prefix}COLOR_INFO`],
|
|
72792
|
-
warning: process.env[`${prefix}COLOR_WARNING`],
|
|
72793
|
-
error: process.env[`${prefix}COLOR_ERROR`],
|
|
72794
|
-
fatal: process.env[`${prefix}COLOR_FATAL`]
|
|
72795
|
-
},
|
|
72796
72894
|
repository: process.env[`${prefix}REPOSITORY`],
|
|
72797
72895
|
branch: process.env[`${prefix}BRANCH`],
|
|
72798
72896
|
preid: process.env[`${prefix}PRE_ID`],
|
|
@@ -72803,6 +72901,18 @@ var init_get_env = __esm({
|
|
|
72803
72901
|
Number.parseInt(process.env[`${prefix}LOG_LEVEL`])
|
|
72804
72902
|
) : process.env[`${prefix}LOG_LEVEL`] : void 0
|
|
72805
72903
|
};
|
|
72904
|
+
const themeNames = Object.keys(process.env).filter(
|
|
72905
|
+
(envKey) => envKey.startsWith(`${prefix}COLOR_`) && COLOR_KEYS.every(
|
|
72906
|
+
(colorKey) => !envKey.startsWith(`${prefix}COLOR_LIGHT_${colorKey}`) && !envKey.startsWith(`${prefix}COLOR_DARK_${colorKey}`)
|
|
72907
|
+
)
|
|
72908
|
+
);
|
|
72909
|
+
config.colors = themeNames.length > 0 ? themeNames.reduce(
|
|
72910
|
+
(ret, themeName) => {
|
|
72911
|
+
ret[themeName] = getThemeColorConfigEnv(prefix, themeName);
|
|
72912
|
+
return ret;
|
|
72913
|
+
},
|
|
72914
|
+
{}
|
|
72915
|
+
) : getThemeColorConfigEnv(prefix);
|
|
72806
72916
|
const serializedConfig = process.env[`${prefix}CONFIG`];
|
|
72807
72917
|
if (serializedConfig) {
|
|
72808
72918
|
const parsed = JSON.parse(serializedConfig);
|
|
@@ -72815,11 +72925,53 @@ var init_get_env = __esm({
|
|
|
72815
72925
|
}
|
|
72816
72926
|
return config;
|
|
72817
72927
|
};
|
|
72928
|
+
getThemeColorConfigEnv = (prefix, theme) => {
|
|
72929
|
+
const themeName = `COLOR_${theme && theme !== "base" ? `${theme}_` : ""}`.toUpperCase();
|
|
72930
|
+
return process.env[`${prefix}${themeName}LIGHT_PRIMARY`] || process.env[`${prefix}${themeName}DARK_PRIMARY`] ? getMultiThemeColorConfigEnv(prefix + themeName) : getSingleThemeColorConfigEnv(prefix + themeName);
|
|
72931
|
+
};
|
|
72932
|
+
getSingleThemeColorConfigEnv = (prefix) => {
|
|
72933
|
+
return {
|
|
72934
|
+
dark: process.env[`${prefix}DARK`],
|
|
72935
|
+
light: process.env[`${prefix}LIGHT`],
|
|
72936
|
+
primary: process.env[`${prefix}PRIMARY`],
|
|
72937
|
+
secondary: process.env[`${prefix}SECONDARY`],
|
|
72938
|
+
tertiary: process.env[`${prefix}TERTIARY`],
|
|
72939
|
+
accent: process.env[`${prefix}ACCENT`],
|
|
72940
|
+
success: process.env[`${prefix}SUCCESS`],
|
|
72941
|
+
info: process.env[`${prefix}INFO`],
|
|
72942
|
+
warning: process.env[`${prefix}WARNING`],
|
|
72943
|
+
error: process.env[`${prefix}ERROR`],
|
|
72944
|
+
fatal: process.env[`${prefix}FATAL`]
|
|
72945
|
+
};
|
|
72946
|
+
};
|
|
72947
|
+
getMultiThemeColorConfigEnv = (prefix) => {
|
|
72948
|
+
return {
|
|
72949
|
+
light: getBaseThemeColorConfigEnv(
|
|
72950
|
+
`${prefix}_LIGHT_`
|
|
72951
|
+
),
|
|
72952
|
+
dark: getBaseThemeColorConfigEnv(`${prefix}_DARK_`)
|
|
72953
|
+
};
|
|
72954
|
+
};
|
|
72955
|
+
getBaseThemeColorConfigEnv = (prefix) => {
|
|
72956
|
+
return {
|
|
72957
|
+
foreground: process.env[`${prefix}FOREGROUND`],
|
|
72958
|
+
background: process.env[`${prefix}BACKGROUND`],
|
|
72959
|
+
primary: process.env[`${prefix}PRIMARY`],
|
|
72960
|
+
secondary: process.env[`${prefix}SECONDARY`],
|
|
72961
|
+
tertiary: process.env[`${prefix}TERTIARY`],
|
|
72962
|
+
accent: process.env[`${prefix}ACCENT`],
|
|
72963
|
+
success: process.env[`${prefix}SUCCESS`],
|
|
72964
|
+
info: process.env[`${prefix}INFO`],
|
|
72965
|
+
warning: process.env[`${prefix}WARNING`],
|
|
72966
|
+
error: process.env[`${prefix}ERROR`],
|
|
72967
|
+
fatal: process.env[`${prefix}FATAL`]
|
|
72968
|
+
};
|
|
72969
|
+
};
|
|
72818
72970
|
}
|
|
72819
72971
|
});
|
|
72820
72972
|
|
|
72821
72973
|
// packages/config-tools/src/env/set-env.ts
|
|
72822
|
-
var setExtensionEnv, setConfigEnv;
|
|
72974
|
+
var setExtensionEnv, setConfigEnv, setThemeColorConfigEnv, setSingleThemeColorConfigEnv, setMultiThemeColorConfigEnv, setBaseThemeColorConfigEnv;
|
|
72823
72975
|
var init_set_env = __esm({
|
|
72824
72976
|
"packages/config-tools/src/env/set-env.ts"() {
|
|
72825
72977
|
init_types2();
|
|
@@ -72935,29 +73087,15 @@ var init_set_env = __esm({
|
|
|
72935
73087
|
process.env.CI = String(config.ci);
|
|
72936
73088
|
process.env.CONTINUOUS_INTEGRATION = String(config.ci);
|
|
72937
73089
|
}
|
|
72938
|
-
if (config.colors.
|
|
72939
|
-
|
|
72940
|
-
|
|
72941
|
-
|
|
72942
|
-
|
|
72943
|
-
|
|
72944
|
-
|
|
72945
|
-
|
|
72946
|
-
|
|
72947
|
-
if (config.colors.success) {
|
|
72948
|
-
process.env[`${prefix}COLOR_SUCCESS`] = config.colors.success;
|
|
72949
|
-
}
|
|
72950
|
-
if (config.colors.info) {
|
|
72951
|
-
process.env[`${prefix}COLOR_INFO`] = config.colors.info;
|
|
72952
|
-
}
|
|
72953
|
-
if (config.colors.warning) {
|
|
72954
|
-
process.env[`${prefix}COLOR_WARNING`] = config.colors.warning;
|
|
72955
|
-
}
|
|
72956
|
-
if (config.colors.error) {
|
|
72957
|
-
process.env[`${prefix}COLOR_ERROR`] = config.colors.error;
|
|
72958
|
-
}
|
|
72959
|
-
if (config.colors.fatal) {
|
|
72960
|
-
process.env[`${prefix}COLOR_FATAL`] = config.colors.fatal;
|
|
73090
|
+
if (config.colors?.base?.light || config.colors?.base?.dark) {
|
|
73091
|
+
for (const key of Object.keys(config.colors)) {
|
|
73092
|
+
setThemeColorConfigEnv(`${prefix}COLOR_${key}_`, config.colors[key]);
|
|
73093
|
+
}
|
|
73094
|
+
} else {
|
|
73095
|
+
setThemeColorConfigEnv(
|
|
73096
|
+
`${prefix}COLOR_`,
|
|
73097
|
+
config.colors
|
|
73098
|
+
);
|
|
72961
73099
|
}
|
|
72962
73100
|
if (config.repository) {
|
|
72963
73101
|
process.env[`${prefix}REPOSITORY`] = config.repository;
|
|
@@ -72986,11 +73124,90 @@ var init_set_env = __esm({
|
|
|
72986
73124
|
config.extensions[key] && Object.keys(config.extensions[key]) && setExtensionEnv(key, config.extensions[key]);
|
|
72987
73125
|
}
|
|
72988
73126
|
};
|
|
73127
|
+
setThemeColorConfigEnv = (prefix, config) => {
|
|
73128
|
+
return config?.light?.primary || config?.dark?.primary ? setMultiThemeColorConfigEnv(prefix, config) : setSingleThemeColorConfigEnv(prefix, config);
|
|
73129
|
+
};
|
|
73130
|
+
setSingleThemeColorConfigEnv = (prefix, config) => {
|
|
73131
|
+
if (config.dark) {
|
|
73132
|
+
process.env[`${prefix}DARK`] = config.dark;
|
|
73133
|
+
}
|
|
73134
|
+
if (config.light) {
|
|
73135
|
+
process.env[`${prefix}LIGHT`] = config.light;
|
|
73136
|
+
}
|
|
73137
|
+
if (config.primary) {
|
|
73138
|
+
process.env[`${prefix}PRIMARY`] = config.primary;
|
|
73139
|
+
}
|
|
73140
|
+
if (config.secondary) {
|
|
73141
|
+
process.env[`${prefix}SECONDARY`] = config.secondary;
|
|
73142
|
+
}
|
|
73143
|
+
if (config.tertiary) {
|
|
73144
|
+
process.env[`${prefix}TERTIARY`] = config.tertiary;
|
|
73145
|
+
}
|
|
73146
|
+
if (config.accent) {
|
|
73147
|
+
process.env[`${prefix}ACCENT`] = config.accent;
|
|
73148
|
+
}
|
|
73149
|
+
if (config.success) {
|
|
73150
|
+
process.env[`${prefix}SUCCESS`] = config.success;
|
|
73151
|
+
}
|
|
73152
|
+
if (config.info) {
|
|
73153
|
+
process.env[`${prefix}INFO`] = config.info;
|
|
73154
|
+
}
|
|
73155
|
+
if (config.warning) {
|
|
73156
|
+
process.env[`${prefix}WARNING`] = config.warning;
|
|
73157
|
+
}
|
|
73158
|
+
if (config.error) {
|
|
73159
|
+
process.env[`${prefix}ERROR`] = config.error;
|
|
73160
|
+
}
|
|
73161
|
+
if (config.fatal) {
|
|
73162
|
+
process.env[`${prefix}FATAL`] = config.fatal;
|
|
73163
|
+
}
|
|
73164
|
+
};
|
|
73165
|
+
setMultiThemeColorConfigEnv = (prefix, config) => {
|
|
73166
|
+
return {
|
|
73167
|
+
light: setBaseThemeColorConfigEnv(`${prefix}_LIGHT_`, config.light),
|
|
73168
|
+
dark: setBaseThemeColorConfigEnv(`${prefix}_DARK_`, config.dark)
|
|
73169
|
+
};
|
|
73170
|
+
};
|
|
73171
|
+
setBaseThemeColorConfigEnv = (prefix, config) => {
|
|
73172
|
+
if (config.foreground) {
|
|
73173
|
+
process.env[`${prefix}FOREGROUND`] = config.foreground;
|
|
73174
|
+
}
|
|
73175
|
+
if (config.background) {
|
|
73176
|
+
process.env[`${prefix}BACKGROUND`] = config.background;
|
|
73177
|
+
}
|
|
73178
|
+
if (config.primary) {
|
|
73179
|
+
process.env[`${prefix}PRIMARY`] = config.primary;
|
|
73180
|
+
}
|
|
73181
|
+
if (config.secondary) {
|
|
73182
|
+
process.env[`${prefix}SECONDARY`] = config.secondary;
|
|
73183
|
+
}
|
|
73184
|
+
if (config.tertiary) {
|
|
73185
|
+
process.env[`${prefix}TERTIARY`] = config.tertiary;
|
|
73186
|
+
}
|
|
73187
|
+
if (config.accent) {
|
|
73188
|
+
process.env[`${prefix}ACCENT`] = config.accent;
|
|
73189
|
+
}
|
|
73190
|
+
if (config.success) {
|
|
73191
|
+
process.env[`${prefix}SUCCESS`] = config.success;
|
|
73192
|
+
}
|
|
73193
|
+
if (config.info) {
|
|
73194
|
+
process.env[`${prefix}INFO`] = config.info;
|
|
73195
|
+
}
|
|
73196
|
+
if (config.warning) {
|
|
73197
|
+
process.env[`${prefix}WARNING`] = config.warning;
|
|
73198
|
+
}
|
|
73199
|
+
if (config.error) {
|
|
73200
|
+
process.env[`${prefix}ERROR`] = config.error;
|
|
73201
|
+
}
|
|
73202
|
+
if (config.fatal) {
|
|
73203
|
+
process.env[`${prefix}FATAL`] = config.fatal;
|
|
73204
|
+
}
|
|
73205
|
+
};
|
|
72989
73206
|
}
|
|
72990
73207
|
});
|
|
72991
73208
|
|
|
72992
73209
|
// packages/config-tools/src/create-storm-config.ts
|
|
72993
|
-
var _extension_cache, _static_cache, createConfig, createStormConfig, createConfigExtension, loadStormConfig;
|
|
73210
|
+
var import_deepmerge2, _extension_cache, _static_cache, createConfig, createStormConfig, createConfigExtension, loadStormConfig;
|
|
72994
73211
|
var init_create_storm_config = __esm({
|
|
72995
73212
|
"packages/config-tools/src/create-storm-config.ts"() {
|
|
72996
73213
|
init_get_config_file();
|
|
@@ -72999,6 +73216,7 @@ var init_create_storm_config = __esm({
|
|
|
72999
73216
|
init_schema();
|
|
73000
73217
|
init_utilities();
|
|
73001
73218
|
init_get_default_config();
|
|
73219
|
+
import_deepmerge2 = __toESM(require_cjs());
|
|
73002
73220
|
_extension_cache = /* @__PURE__ */ new WeakMap();
|
|
73003
73221
|
_static_cache = void 0;
|
|
73004
73222
|
createConfig = (workspaceRoot) => {
|
|
@@ -73047,7 +73265,9 @@ var init_create_storm_config = __esm({
|
|
|
73047
73265
|
if (!_workspaceRoot) {
|
|
73048
73266
|
_workspaceRoot = findWorkspaceRoot();
|
|
73049
73267
|
}
|
|
73050
|
-
|
|
73268
|
+
let configFile = await getConfigFile(
|
|
73269
|
+
_workspaceRoot
|
|
73270
|
+
);
|
|
73051
73271
|
if (!configFile) {
|
|
73052
73272
|
writeWarning(
|
|
73053
73273
|
"No Storm config file found in the current workspace. Please ensure this is the expected behavior - you can add a `storm.json` file to the root of your workspace if it is not.\n",
|
|
@@ -73056,10 +73276,7 @@ var init_create_storm_config = __esm({
|
|
|
73056
73276
|
}
|
|
73057
73277
|
config = StormConfigSchema.parse(
|
|
73058
73278
|
await getDefaultConfig(
|
|
73059
|
-
{
|
|
73060
|
-
...getConfigEnv(),
|
|
73061
|
-
...configFile
|
|
73062
|
-
},
|
|
73279
|
+
(0, import_deepmerge2.default)(getConfigEnv(), configFile, {}),
|
|
73063
73280
|
_workspaceRoot
|
|
73064
73281
|
)
|
|
73065
73282
|
);
|
|
@@ -73097,6 +73314,7 @@ __export(src_exports, {
|
|
|
73097
73314
|
findFileName: () => findFileName,
|
|
73098
73315
|
findWorkspaceRoot: () => findWorkspaceRoot,
|
|
73099
73316
|
findWorkspaceRootSafe: () => findWorkspaceRootSafe,
|
|
73317
|
+
formatLogMessage: () => formatLogMessage,
|
|
73100
73318
|
getChalk: () => getChalk,
|
|
73101
73319
|
getConfigEnv: () => getConfigEnv,
|
|
73102
73320
|
getConfigFile: () => getConfigFile,
|
|
@@ -223339,7 +223557,7 @@ ${lanes.join("\n")}
|
|
|
223339
223557
|
return true;
|
|
223340
223558
|
}
|
|
223341
223559
|
if (shouldReallyMerge(a2.node, b6.node, parent2)) {
|
|
223342
|
-
|
|
223560
|
+
merge3(a2, b6);
|
|
223343
223561
|
return true;
|
|
223344
223562
|
}
|
|
223345
223563
|
return false;
|
|
@@ -223373,7 +223591,7 @@ ${lanes.join("\n")}
|
|
|
223373
223591
|
}
|
|
223374
223592
|
return a2.body.kind === b6.body.kind && (a2.body.kind !== 267 || areSameModule(a2.body, b6.body));
|
|
223375
223593
|
}
|
|
223376
|
-
function
|
|
223594
|
+
function merge3(target, source) {
|
|
223377
223595
|
target.additionalNodes = target.additionalNodes || [];
|
|
223378
223596
|
target.additionalNodes.push(source.node);
|
|
223379
223597
|
if (source.additionalNodes) {
|
|
@@ -287875,8 +288093,8 @@ var require_merge2 = __commonJS({
|
|
|
287875
288093
|
var Stream = require("stream");
|
|
287876
288094
|
var PassThrough = Stream.PassThrough;
|
|
287877
288095
|
var slice = Array.prototype.slice;
|
|
287878
|
-
module2.exports =
|
|
287879
|
-
function
|
|
288096
|
+
module2.exports = merge22;
|
|
288097
|
+
function merge22() {
|
|
287880
288098
|
const streamsQueue = [];
|
|
287881
288099
|
const args = slice.call(arguments);
|
|
287882
288100
|
let merging = false;
|
|
@@ -287993,9 +288211,9 @@ var require_stream = __commonJS({
|
|
|
287993
288211
|
"use strict";
|
|
287994
288212
|
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
287995
288213
|
exports2.merge = void 0;
|
|
287996
|
-
var
|
|
288214
|
+
var merge22 = require_merge2();
|
|
287997
288215
|
function merge3(streams) {
|
|
287998
|
-
const mergedStream =
|
|
288216
|
+
const mergedStream = merge22(streams);
|
|
287999
288217
|
streams.forEach((stream) => {
|
|
288000
288218
|
stream.once("error", (error) => mergedStream.emit("error", error));
|
|
288001
288219
|
});
|
|
@@ -294911,7 +295129,7 @@ var withRunExecutor = (name, executorFn, executorOptions) => async (_options, co
|
|
|
294911
295129
|
writeTrace2(
|
|
294912
295130
|
`Loaded Storm config into env:
|
|
294913
295131
|
${Object.keys(process.env).filter((key) => key.startsWith("STORM_")).map(
|
|
294914
|
-
(key) => ` - ${key}=${
|
|
295132
|
+
(key) => ` - ${key}=${_isFunction2(process.env[key]) ? "<function>" : JSON.stringify(process.env[key])}`
|
|
294915
295133
|
).join("\n")}`,
|
|
294916
295134
|
config
|
|
294917
295135
|
);
|
|
@@ -294926,7 +295144,7 @@ ${Object.keys(process.env).filter((key) => key.startsWith("STORM_")).map(
|
|
|
294926
295144
|
writeTrace2(
|
|
294927
295145
|
`Executor schema options \u2699\uFE0F
|
|
294928
295146
|
${Object.keys(options).map(
|
|
294929
|
-
(key) => ` - ${key}=${
|
|
295147
|
+
(key) => ` - ${key}=${_isFunction2(options[key]) ? "<function>" : JSON.stringify(options[key])}`
|
|
294930
295148
|
).join("\n")}`,
|
|
294931
295149
|
config
|
|
294932
295150
|
);
|
|
@@ -294951,7 +295169,7 @@ ${Object.keys(options).map(
|
|
|
294951
295169
|
writeDebug2("Completed the preProcess hook", config);
|
|
294952
295170
|
}
|
|
294953
295171
|
const ret = executorFn(tokenized, context, config);
|
|
294954
|
-
if (
|
|
295172
|
+
if (_isFunction2(ret?.next)) {
|
|
294955
295173
|
const asyncGen = ret;
|
|
294956
295174
|
for await (const iter of asyncGen) {
|
|
294957
295175
|
}
|
|
@@ -294992,7 +295210,7 @@ ${Object.keys(options).map(
|
|
|
294992
295210
|
stopwatch();
|
|
294993
295211
|
}
|
|
294994
295212
|
};
|
|
294995
|
-
var
|
|
295213
|
+
var _isFunction2 = (value2) => {
|
|
294996
295214
|
try {
|
|
294997
295215
|
return value2 instanceof Function || typeof value2 === "function" || !!(value2?.constructor && value2?.call && value2?.apply);
|
|
294998
295216
|
} catch (e2) {
|