@storm-software/cloudflare-tools 0.24.1 → 0.26.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/CHANGELOG.md +14 -0
- package/README.md +1 -1
- package/generators.json +3 -0
- package/index.js +91 -80
- package/meta.json +1 -1
- package/package.json +1 -1
- package/packages/build-tools/src/utils/generate-package-json.d.ts +1 -0
- package/packages/config/src/define-config.d.ts +0 -1
- package/packages/config/src/schema.d.ts +0 -3
- package/packages/config-tools/src/utilities/run.d.ts +3 -1
- package/packages/workspace-tools/src/base/base-executor.d.ts +5 -2
- package/packages/workspace-tools/src/generators/init/init.d.ts +2 -2
- package/src/executors/cloudflare-publish/executor.js +86 -75
- package/src/executors/serve/executor.js +86 -75
- package/src/generators/init/generator.js +1 -1
- package/src/generators/worker/generator.js +25 -17
|
@@ -65447,9 +65447,6 @@ var init_schema = __esm({
|
|
|
65447
65447
|
"The worker of the package (this is the bot that will be used to perform various tasks)"
|
|
65448
65448
|
),
|
|
65449
65449
|
env: z2.enum(["development", "staging", "production"]).default("production").describe("The current runtime environment of the package"),
|
|
65450
|
-
ci: z2.boolean().default(true).describe(
|
|
65451
|
-
"An indicator specifying if the current environment is a CI environment"
|
|
65452
|
-
),
|
|
65453
65450
|
workspaceRoot: z2.string().trim().default("").describe("The root directory of the workspace"),
|
|
65454
65451
|
packageDirectory: z2.string().trim().optional().describe("The root directory of the package"),
|
|
65455
65452
|
externalPackagePatterns: z2.array(z2.string()).default([]).describe(
|
|
@@ -65576,7 +65573,6 @@ var init_get_default_config = __esm({
|
|
|
65576
65573
|
env: "production",
|
|
65577
65574
|
branch: "main",
|
|
65578
65575
|
organization: "storm-software",
|
|
65579
|
-
ci: true,
|
|
65580
65576
|
configFile: null,
|
|
65581
65577
|
runtimeVersion: "1.0.0",
|
|
65582
65578
|
colors: { ...DEFAULT_COLOR_CONFIG },
|
|
@@ -67483,11 +67479,13 @@ var init_run = __esm({
|
|
|
67483
67479
|
"packages/config-tools/src/utilities/run.ts"() {
|
|
67484
67480
|
import_node_child_process5 = require("node:child_process");
|
|
67485
67481
|
LARGE_BUFFER = 1024 * 1e6;
|
|
67486
|
-
run = (config, command, cwd2 = config.workspaceRoot ?? process.cwd(), stdio = "inherit") => {
|
|
67482
|
+
run = (config, command, cwd2 = config.workspaceRoot ?? process.cwd(), stdio = "inherit", env = process.env) => {
|
|
67487
67483
|
return (0, import_node_child_process5.execSync)(command, {
|
|
67488
67484
|
cwd: cwd2,
|
|
67489
67485
|
env: {
|
|
67490
67486
|
...process.env,
|
|
67487
|
+
...env,
|
|
67488
|
+
CLICOLOR: "true",
|
|
67491
67489
|
FORCE_COLOR: "true"
|
|
67492
67490
|
},
|
|
67493
67491
|
stdio,
|
|
@@ -67729,9 +67727,14 @@ var init_get_env = __esm({
|
|
|
67729
67727
|
runtimeVersion: process.env[`${prefix}RUNTIME_VERSION`],
|
|
67730
67728
|
outputDirectory: correctPaths(process.env[`${prefix}OUTPUT_DIRECTORY`]),
|
|
67731
67729
|
env: process.env[`${prefix}ENV`] ?? process.env.NODE_ENV ?? process.env.ENVIRONMENT,
|
|
67732
|
-
ci:
|
|
67733
|
-
|
|
67734
|
-
|
|
67730
|
+
// ci:
|
|
67731
|
+
// process.env[`${prefix}CI`] !== undefined
|
|
67732
|
+
// ? Boolean(
|
|
67733
|
+
// process.env[`${prefix}CI`] ??
|
|
67734
|
+
// process.env.CI ??
|
|
67735
|
+
// process.env.CONTINUOUS_INTEGRATION
|
|
67736
|
+
// )
|
|
67737
|
+
// : undefined,
|
|
67735
67738
|
repository: process.env[`${prefix}REPOSITORY`],
|
|
67736
67739
|
branch: process.env[`${prefix}BRANCH`],
|
|
67737
67740
|
preid: process.env[`${prefix}PRE_ID`],
|
|
@@ -67932,11 +67935,6 @@ var init_set_env = __esm({
|
|
|
67932
67935
|
process.env.NODE_ENV = config.env;
|
|
67933
67936
|
process.env.ENVIRONMENT = config.env;
|
|
67934
67937
|
}
|
|
67935
|
-
if (config.ci) {
|
|
67936
|
-
process.env[`${prefix}CI`] = String(config.ci);
|
|
67937
|
-
process.env.CI = String(config.ci);
|
|
67938
|
-
process.env.CONTINUOUS_INTEGRATION = String(config.ci);
|
|
67939
|
-
}
|
|
67940
67938
|
if (config.colors?.base?.light || config.colors?.base?.dark) {
|
|
67941
67939
|
for (const key of Object.keys(config.colors)) {
|
|
67942
67940
|
setThemeColorConfigEnv(`${prefix}COLOR_${key}_`, config.colors[key]);
|
|
@@ -68105,7 +68103,7 @@ var init_create_storm_config = __esm({
|
|
|
68105
68103
|
};
|
|
68106
68104
|
createStormConfig = (extensionName, schema, workspaceRoot3) => {
|
|
68107
68105
|
let result;
|
|
68108
|
-
if (!_static_cache) {
|
|
68106
|
+
if (!_static_cache?.data || !_static_cache?.timestamp || _static_cache.timestamp < Date.now() - 3e4) {
|
|
68109
68107
|
const config = getConfigEnv();
|
|
68110
68108
|
const defaultConfig = getDefaultConfig(config, workspaceRoot3);
|
|
68111
68109
|
result = StormConfigSchema.parse({
|
|
@@ -68118,7 +68116,7 @@ var init_create_storm_config = __esm({
|
|
|
68118
68116
|
});
|
|
68119
68117
|
result.workspaceRoot ??= defaultConfig.workspaceRoot ? defaultConfig.workspaceRoot : findWorkspaceRoot(workspaceRoot3);
|
|
68120
68118
|
} else {
|
|
68121
|
-
result = _static_cache;
|
|
68119
|
+
result = _static_cache.data;
|
|
68122
68120
|
}
|
|
68123
68121
|
if (schema && extensionName) {
|
|
68124
68122
|
result.extensions = {
|
|
@@ -68126,7 +68124,10 @@ var init_create_storm_config = __esm({
|
|
|
68126
68124
|
[extensionName]: createConfigExtension(extensionName, schema)
|
|
68127
68125
|
};
|
|
68128
68126
|
}
|
|
68129
|
-
_static_cache =
|
|
68127
|
+
_static_cache = {
|
|
68128
|
+
timestamp: Date.now(),
|
|
68129
|
+
data: result
|
|
68130
|
+
};
|
|
68130
68131
|
return result;
|
|
68131
68132
|
};
|
|
68132
68133
|
createConfigExtension = (extensionName, schema) => {
|
|
@@ -68143,6 +68144,13 @@ var init_create_storm_config = __esm({
|
|
|
68143
68144
|
};
|
|
68144
68145
|
loadStormConfig = async (workspaceRoot3) => {
|
|
68145
68146
|
let config = {};
|
|
68147
|
+
if (_static_cache?.data && _static_cache?.timestamp && _static_cache.timestamp >= Date.now() + 3e4) {
|
|
68148
|
+
writeInfo(
|
|
68149
|
+
`Configuration cache hit - ${_static_cache.timestamp}`,
|
|
68150
|
+
_static_cache.data
|
|
68151
|
+
);
|
|
68152
|
+
return _static_cache.data;
|
|
68153
|
+
}
|
|
68146
68154
|
let _workspaceRoot = workspaceRoot3;
|
|
68147
68155
|
if (!_workspaceRoot) {
|
|
68148
68156
|
_workspaceRoot = findWorkspaceRoot();
|
|
@@ -207092,9 +207100,9 @@ ${lanes.join("\n")}
|
|
|
207092
207100
|
function checkDeprecations(deprecatedIn, stopsWorkingIn, removedIn, createDiagnostic, fn2) {
|
|
207093
207101
|
const deprecatedInVersion = new Version(deprecatedIn);
|
|
207094
207102
|
const removedInVersion = new Version(removedIn);
|
|
207095
|
-
const
|
|
207103
|
+
const typescriptVersion = new Version(typeScriptVersion3 || versionMajorMinor);
|
|
207096
207104
|
const ignoreDeprecationsVersion = getIgnoreDeprecationsVersion();
|
|
207097
|
-
const mustBeRemoved = !(removedInVersion.compareTo(
|
|
207105
|
+
const mustBeRemoved = !(removedInVersion.compareTo(typescriptVersion) === 1);
|
|
207098
207106
|
const canBeSilenced = !mustBeRemoved && ignoreDeprecationsVersion.compareTo(deprecatedInVersion) === -1;
|
|
207099
207107
|
if (mustBeRemoved || canBeSilenced) {
|
|
207100
207108
|
fn2((name, value2, useInstead) => {
|
|
@@ -421427,9 +421435,9 @@ ${lanes.join("\n")}
|
|
|
421427
421435
|
function checkDeprecations(deprecatedIn, removedIn, createDiagnostic, fn2) {
|
|
421428
421436
|
const deprecatedInVersion = new Version(deprecatedIn);
|
|
421429
421437
|
const removedInVersion = new Version(removedIn);
|
|
421430
|
-
const
|
|
421438
|
+
const typescriptVersion = new Version(typeScriptVersion3 || versionMajorMinor);
|
|
421431
421439
|
const ignoreDeprecationsVersion = getIgnoreDeprecationsVersion();
|
|
421432
|
-
const mustBeRemoved = !(removedInVersion.compareTo(
|
|
421440
|
+
const mustBeRemoved = !(removedInVersion.compareTo(typescriptVersion) === 1);
|
|
421433
421441
|
const canBeSilenced = !mustBeRemoved && ignoreDeprecationsVersion.compareTo(deprecatedInVersion) === -1;
|
|
421434
421442
|
if (mustBeRemoved || canBeSilenced) {
|
|
421435
421443
|
fn2((name, value2, useInstead) => {
|
|
@@ -606018,7 +606026,7 @@ var applyWorkspaceExecutorTokens = async (option, tokenizerOptions) => {
|
|
|
606018
606026
|
};
|
|
606019
606027
|
|
|
606020
606028
|
// packages/workspace-tools/src/base/base-executor.ts
|
|
606021
|
-
var withRunExecutor = (name, executorFn, executorOptions) => async (_options, context) => {
|
|
606029
|
+
var withRunExecutor = (name, executorFn, executorOptions = {}) => async (_options, context) => {
|
|
606022
606030
|
const {
|
|
606023
606031
|
getStopwatch: getStopwatch2,
|
|
606024
606032
|
writeDebug: writeDebug2,
|
|
@@ -606246,7 +606254,6 @@ var import_generator = __toESM(require_generator());
|
|
|
606246
606254
|
|
|
606247
606255
|
// packages/workspace-tools/src/utils/versions.ts
|
|
606248
606256
|
var typesNodeVersion = "20.9.0";
|
|
606249
|
-
var typescriptVersion = "~5.2.2";
|
|
606250
606257
|
var nxVersion = "^18.0.4";
|
|
606251
606258
|
var nodeVersion = "20.11.0";
|
|
606252
606259
|
var pnpmVersion = "8.10.2";
|
|
@@ -618587,7 +618594,7 @@ async function presetGeneratorFn(tree, options) {
|
|
|
618587
618594
|
];
|
|
618588
618595
|
json.homepage ??= "https://stormsoftware.com";
|
|
618589
618596
|
json.bugs ??= {
|
|
618590
|
-
url:
|
|
618597
|
+
url: `https://github.com/${options.organization}/${options.name}/issues`,
|
|
618591
618598
|
email: "support@stormsoftware.com"
|
|
618592
618599
|
};
|
|
618593
618600
|
json.license = "Apache-2.0";
|
|
@@ -618596,17 +618603,49 @@ async function presetGeneratorFn(tree, options) {
|
|
|
618596
618603
|
email: "contact@stormsoftware.com",
|
|
618597
618604
|
url: "https://stormsoftware.com"
|
|
618598
618605
|
};
|
|
618606
|
+
json.maintainers ??= [
|
|
618607
|
+
{
|
|
618608
|
+
"name": "Storm Software",
|
|
618609
|
+
"email": "contact@stormsoftware.com",
|
|
618610
|
+
"url": "https://stormsoftware.com"
|
|
618611
|
+
},
|
|
618612
|
+
{
|
|
618613
|
+
"name": "Pat Sullivan",
|
|
618614
|
+
"email": "pat@stormsoftware.com",
|
|
618615
|
+
"url": "https://patsullivan.org"
|
|
618616
|
+
}
|
|
618617
|
+
];
|
|
618599
618618
|
json.funding ??= {
|
|
618600
618619
|
type: "github",
|
|
618601
618620
|
url: "https://github.com/sponsors/storm-software"
|
|
618602
618621
|
};
|
|
618603
618622
|
json.namespace ??= `@${options.namespace}`;
|
|
618604
618623
|
json.description ??= options.description;
|
|
618605
|
-
options.repositoryUrl ??= `https://github.com/${options.organization}/${options.name}
|
|
618624
|
+
options.repositoryUrl ??= `https://github.com/${options.organization}/${options.name}`;
|
|
618606
618625
|
json.repository ??= {
|
|
618607
618626
|
type: "github",
|
|
618608
618627
|
url: `${options.repositoryUrl}.git`
|
|
618609
618628
|
};
|
|
618629
|
+
json.packageManager ??= "pnpm@9.6.0";
|
|
618630
|
+
json.engines ??= {
|
|
618631
|
+
"node": ">=20.11.0",
|
|
618632
|
+
"pnpm": ">=9.6.0"
|
|
618633
|
+
};
|
|
618634
|
+
json.devEngines ??= {
|
|
618635
|
+
"node": "20.x || 21.x"
|
|
618636
|
+
};
|
|
618637
|
+
json.nx ??= {
|
|
618638
|
+
"includedScripts": [
|
|
618639
|
+
"lint-ls",
|
|
618640
|
+
"lint",
|
|
618641
|
+
"format",
|
|
618642
|
+
"format-readme",
|
|
618643
|
+
"format-prettier",
|
|
618644
|
+
"format-toml",
|
|
618645
|
+
"commit",
|
|
618646
|
+
"release"
|
|
618647
|
+
]
|
|
618648
|
+
};
|
|
618610
618649
|
json.scripts.adr = "pnpm log4brains adr new";
|
|
618611
618650
|
json.scripts["adr-preview"] = "pnpm log4brains preview";
|
|
618612
618651
|
json.scripts.prepare = "pnpm add lefthook -w && pnpm lefthook install";
|
|
@@ -618663,25 +618702,6 @@ async function presetGeneratorFn(tree, options) {
|
|
|
618663
618702
|
node: `>=${nodeVersion}`,
|
|
618664
618703
|
pnpm: `>=${pnpmVersion}`
|
|
618665
618704
|
};
|
|
618666
|
-
if (options.includeApps) {
|
|
618667
|
-
json.bundlewatch = {
|
|
618668
|
-
files: [
|
|
618669
|
-
{
|
|
618670
|
-
path: "dist/*/*.js",
|
|
618671
|
-
maxSize: "200kB"
|
|
618672
|
-
}
|
|
618673
|
-
],
|
|
618674
|
-
ci: {
|
|
618675
|
-
trackBranches: ["main", "alpha", "beta"]
|
|
618676
|
-
}
|
|
618677
|
-
};
|
|
618678
|
-
json.nextBundleAnalysis = {
|
|
618679
|
-
buildOutputDirectory: "dist/apps/web/app/.next"
|
|
618680
|
-
};
|
|
618681
|
-
}
|
|
618682
|
-
json.nx = {
|
|
618683
|
-
includedScripts: ["lint", "format"]
|
|
618684
|
-
};
|
|
618685
618705
|
return json;
|
|
618686
618706
|
});
|
|
618687
618707
|
(0, import_devkit10.generateFiles)(tree, path7.join(__dirname, "files"), projectRoot, {
|
|
@@ -618691,15 +618711,15 @@ async function presetGeneratorFn(tree, options) {
|
|
|
618691
618711
|
});
|
|
618692
618712
|
await (0, import_devkit10.formatFiles)(tree);
|
|
618693
618713
|
let dependencies = {
|
|
618694
|
-
"@commitlint/cli": "19.2.1",
|
|
618695
618714
|
"@ls-lint/ls-lint": "2.2.3",
|
|
618696
618715
|
"@ltd/j-toml": "1.38.0",
|
|
618697
|
-
"@
|
|
618698
|
-
"@nx/
|
|
618699
|
-
"@nx/
|
|
618700
|
-
"@nx/
|
|
618701
|
-
"@nx/
|
|
618702
|
-
"@nx/
|
|
618716
|
+
"@microsoft/tsdoc": "0.15.0",
|
|
618717
|
+
"@nx/devkit": "^19.5.3",
|
|
618718
|
+
"@nx/esbuild": "19.5.3",
|
|
618719
|
+
"@nx/eslint-plugin": ">=19.5.3",
|
|
618720
|
+
"@nx/js": "^19.5.3",
|
|
618721
|
+
"@nx/plugin": "19.5.3",
|
|
618722
|
+
"@nx/workspace": "^19.5.3",
|
|
618703
618723
|
"@storm-software/config": "latest",
|
|
618704
618724
|
"@storm-software/config-tools": "latest",
|
|
618705
618725
|
"@storm-software/git-tools": "latest",
|
|
@@ -618709,44 +618729,35 @@ async function presetGeneratorFn(tree, options) {
|
|
|
618709
618729
|
"@storm-software/eslint": "latest",
|
|
618710
618730
|
"@storm-software/eslint-plugin": "latest",
|
|
618711
618731
|
"@storm-software/prettier": "latest",
|
|
618712
|
-
"@swc-node/register": "1.9.0",
|
|
618713
|
-
"@swc/cli": "0.3.12",
|
|
618714
|
-
"@swc/core": "1.4.12",
|
|
618715
|
-
"@swc/helpers": "0.5.8",
|
|
618716
|
-
"@swc/wasm": "1.4.12",
|
|
618717
618732
|
"@taplo/cli": "0.7.0",
|
|
618718
618733
|
"@types/jest": "29.5.12",
|
|
618719
|
-
"@types/node": "20.
|
|
618720
|
-
"conventional-changelog-conventionalcommits": "
|
|
618721
|
-
"
|
|
618734
|
+
"@types/node": "^20.14.10",
|
|
618735
|
+
"conventional-changelog-conventionalcommits": "8.0.0",
|
|
618736
|
+
"copyfiles": "2.4.1",
|
|
618737
|
+
"esbuild": "0.21.5",
|
|
618722
618738
|
"esbuild-register": "3.5.0",
|
|
618723
|
-
"eslint": "
|
|
618724
|
-
"eslint-config-storm-software": "latest",
|
|
618725
|
-
"eslint-plugin-import": "^2.29.1",
|
|
618726
|
-
"eslint-plugin-jsx-a11y": "^6.8.0",
|
|
618727
|
-
"eslint-plugin-react": "^7.34.1",
|
|
618728
|
-
"eslint-plugin-react-hooks": "^4.6.0",
|
|
618739
|
+
"eslint": "9.5.0",
|
|
618729
618740
|
"jest": "29.7.0",
|
|
618730
618741
|
"jest-environment-jsdom": "29.7.0",
|
|
618731
618742
|
"jest-environment-node": "29.7.0",
|
|
618732
|
-
"
|
|
618733
|
-
"
|
|
618734
|
-
"
|
|
618735
|
-
"
|
|
618736
|
-
"
|
|
618743
|
+
"knip": "5.25.2",
|
|
618744
|
+
"lefthook": "1.6.18",
|
|
618745
|
+
"nx": "^19.5.3",
|
|
618746
|
+
"prettier": "3.3.2",
|
|
618747
|
+
"prettier-plugin-prisma": "5.0.0",
|
|
618748
|
+
"rimraf": "5.0.7",
|
|
618749
|
+
"sherif": "0.10.0",
|
|
618750
|
+
"ts-jest": "29.1.5",
|
|
618737
618751
|
"ts-loader": "9.5.1",
|
|
618738
618752
|
"ts-node": "10.9.2",
|
|
618739
618753
|
"tsconfig-paths": "4.2.0",
|
|
618740
|
-
"tslib": "2.6.
|
|
618741
|
-
"typescript":
|
|
618742
|
-
"verdaccio": "5.
|
|
618743
|
-
"knip": "5.25.2",
|
|
618744
|
-
"sherif": "0.10.0"
|
|
618754
|
+
"tslib": "2.6.3",
|
|
618755
|
+
"typescript": "5.5.3",
|
|
618756
|
+
"verdaccio": "5.31.1"
|
|
618745
618757
|
};
|
|
618746
618758
|
if (options.includeApps) {
|
|
618747
618759
|
dependencies = {
|
|
618748
618760
|
...dependencies,
|
|
618749
|
-
bundlewatch: "latest",
|
|
618750
618761
|
react: "latest",
|
|
618751
618762
|
"react-dom": "latest",
|
|
618752
618763
|
storybook: "latest",
|
|
@@ -427545,7 +427545,7 @@ var require_package3 = __commonJS({
|
|
|
427545
427545
|
"packages/cloudflare-tools/package.json"(exports2, module2) {
|
|
427546
427546
|
module2.exports = {
|
|
427547
427547
|
name: "@storm-software/cloudflare-tools",
|
|
427548
|
-
version: "0.
|
|
427548
|
+
version: "0.26.0",
|
|
427549
427549
|
type: "commonjs",
|
|
427550
427550
|
description: "\u26A1The Storm-Ops monorepo contains utility applications, tools, and various libraries to create modern and scalable web applications.",
|
|
427551
427551
|
repository: {
|
|
@@ -660097,7 +660097,7 @@ var require_package13 = __commonJS({
|
|
|
660097
660097
|
"packages/cloudflare-tools/package.json"(exports2, module2) {
|
|
660098
660098
|
module2.exports = {
|
|
660099
660099
|
name: "@storm-software/cloudflare-tools",
|
|
660100
|
-
version: "0.
|
|
660100
|
+
version: "0.26.0",
|
|
660101
660101
|
type: "commonjs",
|
|
660102
660102
|
description: "\u26A1The Storm-Ops monorepo contains utility applications, tools, and various libraries to create modern and scalable web applications.",
|
|
660103
660103
|
repository: {
|
|
@@ -725451,9 +725451,6 @@ var init_schema = __esm({
|
|
|
725451
725451
|
"The worker of the package (this is the bot that will be used to perform various tasks)"
|
|
725452
725452
|
),
|
|
725453
725453
|
env: z2.enum(["development", "staging", "production"]).default("production").describe("The current runtime environment of the package"),
|
|
725454
|
-
ci: z2.boolean().default(true).describe(
|
|
725455
|
-
"An indicator specifying if the current environment is a CI environment"
|
|
725456
|
-
),
|
|
725457
725454
|
workspaceRoot: z2.string().trim().default("").describe("The root directory of the workspace"),
|
|
725458
725455
|
packageDirectory: z2.string().trim().optional().describe("The root directory of the package"),
|
|
725459
725456
|
externalPackagePatterns: z2.array(z2.string()).default([]).describe(
|
|
@@ -725580,7 +725577,6 @@ var init_get_default_config = __esm({
|
|
|
725580
725577
|
env: "production",
|
|
725581
725578
|
branch: "main",
|
|
725582
725579
|
organization: "storm-software",
|
|
725583
|
-
ci: true,
|
|
725584
725580
|
configFile: null,
|
|
725585
725581
|
runtimeVersion: "1.0.0",
|
|
725586
725582
|
colors: { ...DEFAULT_COLOR_CONFIG },
|
|
@@ -725940,11 +725936,13 @@ var init_run = __esm({
|
|
|
725940
725936
|
"packages/config-tools/src/utilities/run.ts"() {
|
|
725941
725937
|
import_node_child_process5 = require("node:child_process");
|
|
725942
725938
|
LARGE_BUFFER = 1024 * 1e6;
|
|
725943
|
-
run = (config, command, cwd2 = config.workspaceRoot ?? process.cwd(), stdio = "inherit") => {
|
|
725939
|
+
run = (config, command, cwd2 = config.workspaceRoot ?? process.cwd(), stdio = "inherit", env = process.env) => {
|
|
725944
725940
|
return (0, import_node_child_process5.execSync)(command, {
|
|
725945
725941
|
cwd: cwd2,
|
|
725946
725942
|
env: {
|
|
725947
725943
|
...process.env,
|
|
725944
|
+
...env,
|
|
725945
|
+
CLICOLOR: "true",
|
|
725948
725946
|
FORCE_COLOR: "true"
|
|
725949
725947
|
},
|
|
725950
725948
|
stdio,
|
|
@@ -726186,9 +726184,14 @@ var init_get_env = __esm({
|
|
|
726186
726184
|
runtimeVersion: process.env[`${prefix}RUNTIME_VERSION`],
|
|
726187
726185
|
outputDirectory: correctPaths(process.env[`${prefix}OUTPUT_DIRECTORY`]),
|
|
726188
726186
|
env: process.env[`${prefix}ENV`] ?? process.env.NODE_ENV ?? process.env.ENVIRONMENT,
|
|
726189
|
-
ci:
|
|
726190
|
-
|
|
726191
|
-
|
|
726187
|
+
// ci:
|
|
726188
|
+
// process.env[`${prefix}CI`] !== undefined
|
|
726189
|
+
// ? Boolean(
|
|
726190
|
+
// process.env[`${prefix}CI`] ??
|
|
726191
|
+
// process.env.CI ??
|
|
726192
|
+
// process.env.CONTINUOUS_INTEGRATION
|
|
726193
|
+
// )
|
|
726194
|
+
// : undefined,
|
|
726192
726195
|
repository: process.env[`${prefix}REPOSITORY`],
|
|
726193
726196
|
branch: process.env[`${prefix}BRANCH`],
|
|
726194
726197
|
preid: process.env[`${prefix}PRE_ID`],
|
|
@@ -726389,11 +726392,6 @@ var init_set_env = __esm({
|
|
|
726389
726392
|
process.env.NODE_ENV = config.env;
|
|
726390
726393
|
process.env.ENVIRONMENT = config.env;
|
|
726391
726394
|
}
|
|
726392
|
-
if (config.ci) {
|
|
726393
|
-
process.env[`${prefix}CI`] = String(config.ci);
|
|
726394
|
-
process.env.CI = String(config.ci);
|
|
726395
|
-
process.env.CONTINUOUS_INTEGRATION = String(config.ci);
|
|
726396
|
-
}
|
|
726397
726395
|
if (config.colors?.base?.light || config.colors?.base?.dark) {
|
|
726398
726396
|
for (const key of Object.keys(config.colors)) {
|
|
726399
726397
|
setThemeColorConfigEnv(`${prefix}COLOR_${key}_`, config.colors[key]);
|
|
@@ -726562,7 +726560,7 @@ var init_create_storm_config = __esm({
|
|
|
726562
726560
|
};
|
|
726563
726561
|
createStormConfig = (extensionName, schema, workspaceRoot) => {
|
|
726564
726562
|
let result;
|
|
726565
|
-
if (!_static_cache) {
|
|
726563
|
+
if (!_static_cache?.data || !_static_cache?.timestamp || _static_cache.timestamp < Date.now() - 3e4) {
|
|
726566
726564
|
const config = getConfigEnv();
|
|
726567
726565
|
const defaultConfig = getDefaultConfig(config, workspaceRoot);
|
|
726568
726566
|
result = StormConfigSchema.parse({
|
|
@@ -726575,7 +726573,7 @@ var init_create_storm_config = __esm({
|
|
|
726575
726573
|
});
|
|
726576
726574
|
result.workspaceRoot ??= defaultConfig.workspaceRoot ? defaultConfig.workspaceRoot : findWorkspaceRoot(workspaceRoot);
|
|
726577
726575
|
} else {
|
|
726578
|
-
result = _static_cache;
|
|
726576
|
+
result = _static_cache.data;
|
|
726579
726577
|
}
|
|
726580
726578
|
if (schema && extensionName) {
|
|
726581
726579
|
result.extensions = {
|
|
@@ -726583,7 +726581,10 @@ var init_create_storm_config = __esm({
|
|
|
726583
726581
|
[extensionName]: createConfigExtension(extensionName, schema)
|
|
726584
726582
|
};
|
|
726585
726583
|
}
|
|
726586
|
-
_static_cache =
|
|
726584
|
+
_static_cache = {
|
|
726585
|
+
timestamp: Date.now(),
|
|
726586
|
+
data: result
|
|
726587
|
+
};
|
|
726587
726588
|
return result;
|
|
726588
726589
|
};
|
|
726589
726590
|
createConfigExtension = (extensionName, schema) => {
|
|
@@ -726600,6 +726601,13 @@ var init_create_storm_config = __esm({
|
|
|
726600
726601
|
};
|
|
726601
726602
|
loadStormConfig = async (workspaceRoot) => {
|
|
726602
726603
|
let config = {};
|
|
726604
|
+
if (_static_cache?.data && _static_cache?.timestamp && _static_cache.timestamp >= Date.now() + 3e4) {
|
|
726605
|
+
writeInfo(
|
|
726606
|
+
`Configuration cache hit - ${_static_cache.timestamp}`,
|
|
726607
|
+
_static_cache.data
|
|
726608
|
+
);
|
|
726609
|
+
return _static_cache.data;
|
|
726610
|
+
}
|
|
726603
726611
|
let _workspaceRoot = workspaceRoot;
|
|
726604
726612
|
if (!_workspaceRoot) {
|
|
726605
726613
|
_workspaceRoot = findWorkspaceRoot();
|