@storm-software/config-tools 1.41.1 → 1.41.2

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 CHANGED
@@ -1,3 +1,15 @@
1
+ ## 1.41.2 (2024-04-26)
2
+
3
+
4
+ ### 🩹 Fixes
5
+
6
+ - **config-tools:** Ensure defaulting doesn't overwrite file ([d14794e5](https://github.com/storm-software/storm-ops/commit/d14794e5))
7
+
8
+
9
+ ### ❤️ Thank You
10
+
11
+ - Patrick Sullivan
12
+
1
13
  ## 1.41.1 (2024-04-25)
2
14
 
3
15
 
package/index.cjs CHANGED
@@ -72300,7 +72300,14 @@ var getDefaultConfig = (config = {}, root) => {
72300
72300
  }
72301
72301
  return StormConfigSchema.parse({
72302
72302
  ...DEFAULT_STORM_CONFIG,
72303
- ...config,
72303
+ ...Object.keys(config).reduce((ret, key) => {
72304
+ if (typeof config[key] === "string" && !config[key]) {
72305
+ ret[key] = void 0;
72306
+ } else {
72307
+ ret[key] = config[key];
72308
+ }
72309
+ return ret;
72310
+ }, {}),
72304
72311
  colors: { ...DEFAULT_COLOR_CONFIG, ...config.colors },
72305
72312
  workspaceRoot,
72306
72313
  name,
@@ -73144,13 +73151,15 @@ var loadStormConfig = async (workspaceRoot) => {
73144
73151
  { logLevel: "all" }
73145
73152
  );
73146
73153
  }
73147
- config = StormConfigSchema.parse(
73148
- await getDefaultConfig(
73149
- (0, import_deepmerge2.default)(configFile, getConfigEnv(), {}),
73150
- _workspaceRoot
73151
- )
73154
+ config = getDefaultConfig(
73155
+ (0, import_deepmerge2.default)(getConfigEnv(), configFile, {}),
73156
+ _workspaceRoot
73152
73157
  );
73153
73158
  setConfigEnv(config);
73159
+ writeInfo(`Using Storm configuration:
73160
+ ${formatLogMessage(config)}`, {
73161
+ logLevel: "all"
73162
+ });
73154
73163
  return config;
73155
73164
  };
73156
73165
  // Annotate the CommonJS export names for ESM import in node:
package/index.js CHANGED
@@ -72258,7 +72258,14 @@ var getDefaultConfig = (config = {}, root) => {
72258
72258
  }
72259
72259
  return StormConfigSchema.parse({
72260
72260
  ...DEFAULT_STORM_CONFIG,
72261
- ...config,
72261
+ ...Object.keys(config).reduce((ret, key) => {
72262
+ if (typeof config[key] === "string" && !config[key]) {
72263
+ ret[key] = void 0;
72264
+ } else {
72265
+ ret[key] = config[key];
72266
+ }
72267
+ return ret;
72268
+ }, {}),
72262
72269
  colors: { ...DEFAULT_COLOR_CONFIG, ...config.colors },
72263
72270
  workspaceRoot,
72264
72271
  name,
@@ -73102,13 +73109,15 @@ var loadStormConfig = async (workspaceRoot) => {
73102
73109
  { logLevel: "all" }
73103
73110
  );
73104
73111
  }
73105
- config = StormConfigSchema.parse(
73106
- await getDefaultConfig(
73107
- (0, import_deepmerge2.default)(configFile, getConfigEnv(), {}),
73108
- _workspaceRoot
73109
- )
73112
+ config = getDefaultConfig(
73113
+ (0, import_deepmerge2.default)(getConfigEnv(), configFile, {}),
73114
+ _workspaceRoot
73110
73115
  );
73111
73116
  setConfigEnv(config);
73117
+ writeInfo(`Using Storm configuration:
73118
+ ${formatLogMessage(config)}`, {
73119
+ logLevel: "all"
73120
+ });
73112
73121
  return config;
73113
73122
  };
73114
73123
  export {