tungsten 0.3.4 → 0.3.5
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/dist/.build-complete +1 -1
- package/dist/Framework.js +2 -2
- package/dist/Servers/loadEnvsDev.js +2 -2
- package/dist/componentCss/tungsten.css +2 -2
- package/dist/env/addToEnv.d.ts +2 -0
- package/dist/env/addToEnv.d.ts.map +1 -0
- package/dist/env/{injectEnv.js → addToEnv.js} +1 -1
- package/package.json +1 -1
- package/dist/env/injectEnv.d.ts +0 -2
- package/dist/env/injectEnv.d.ts.map +0 -1
package/dist/.build-complete
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
1785885262718
|
package/dist/Framework.js
CHANGED
|
@@ -25,7 +25,7 @@ import { throwError } from "./throwError.js";
|
|
|
25
25
|
import { existsSync, readFileSync, openSync, closeSync, writeFileSync, copyFileSync } from 'fs';
|
|
26
26
|
import dotenv from 'dotenv';
|
|
27
27
|
import { getEnvSchemas } from "./env/getEnvSchemas.js";
|
|
28
|
-
import {
|
|
28
|
+
import { addToEnv } from "./env/addToEnv.js";
|
|
29
29
|
//import { ValueOf } from 'sxy-lib'
|
|
30
30
|
import { windowGlobalEnvStatement } from "./env/windowGlobalEnvStatement.js";
|
|
31
31
|
import { loadEnvsDev } from "./Servers/loadEnvsDev.js";
|
|
@@ -198,7 +198,7 @@ export class Framework {
|
|
|
198
198
|
const env = dotenv.parse(readFileSync(filePath, 'utf-8'));
|
|
199
199
|
someEnvLoaded = true;
|
|
200
200
|
cliOut(`${fileName} loaded from ${filePath}`);
|
|
201
|
-
|
|
201
|
+
addToEnv(env, process.env, prefix, trueEnv, config.suppressEnvOverwriteWarnings);
|
|
202
202
|
//console.log('process.env after injecting ' + fileName, process.env)
|
|
203
203
|
}
|
|
204
204
|
const projectDir = process.cwd();
|
|
@@ -4,7 +4,7 @@ import { remap as objectRemap, filter as objectFilter } from 'sxy-lib/objects.js
|
|
|
4
4
|
import { getEnvSchemasDev } from "../env/getEnvSchemas.js";
|
|
5
5
|
import dotenv from 'dotenv';
|
|
6
6
|
import { cliLog, cliOut } from "../cliOutput.js";
|
|
7
|
-
import {
|
|
7
|
+
import { addToEnv } from "../env/addToEnv.js";
|
|
8
8
|
import { throwError } from 'tungsten/throwError.js';
|
|
9
9
|
import { tungstenCorePrivateEnvSchema } from "./tungstenCorePrivateEnvSchema.js";
|
|
10
10
|
import { tungstenCorePublicEnvSchema } from "./tungstenCorePublicEnvSchema.js";
|
|
@@ -44,7 +44,7 @@ iteration, initialProcessEnv, _firstLoad, useTestEnvFiles = false) {
|
|
|
44
44
|
someEnvLoaded = true;
|
|
45
45
|
if (_firstLoad) cliOut(`${fileName} loaded from ${filePath}`);
|
|
46
46
|
//cliOut(fileName, JSON.stringify(env, null, 4))
|
|
47
|
-
|
|
47
|
+
addToEnv(env, tempEnv, prefix, initialProcessEnv, config.suppressEnvOverwriteWarnings);
|
|
48
48
|
//if (_firstLoad) console.log('loaded env file', fileName)
|
|
49
49
|
} catch (e) {
|
|
50
50
|
if (e !== null && typeof e === 'object' && 'errno' in e && e.errno === -4058) {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
@import "i/T-components-library-
|
|
2
|
-
@import "i/T-components-library-
|
|
1
|
+
@import "i/T-components-library-__StatefulMessage-StatefulMessage.css";
|
|
2
|
+
@import "i/T-components-library-RichTextEditor-RichTextEditor.css";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"addToEnv.d.ts","sourceRoot":"","sources":["../../src/env/addToEnv.ts"],"names":[],"mappings":"AAGA,wBAAgB,QAAQ,CACpB,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAC9B,GAAG,GAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAe,EAC1C,MAAM,GAAE,MAAW,EAGnB,OAAO,GAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAM,EACrC,yBAAyB,GAAE,OAAe,QAmB7C"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { cliWarn } from "../cliOutput.js";
|
|
2
|
-
export function
|
|
2
|
+
export function addToEnv(newEnv, env = process.env, prefix = '',
|
|
3
3
|
// the real (OS/shell) environment as it was before any .env file was loaded - these values
|
|
4
4
|
// always win over .env files, they're never overwritten, only warned about on conflict
|
|
5
5
|
trueEnv = {}, suppressOverwriteWarnings = false) {
|
package/package.json
CHANGED
package/dist/env/injectEnv.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"injectEnv.d.ts","sourceRoot":"","sources":["../../src/env/injectEnv.ts"],"names":[],"mappings":"AAGA,wBAAgB,SAAS,CACrB,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAC9B,GAAG,GAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAe,EAC1C,MAAM,GAAE,MAAW,EAGnB,OAAO,GAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAM,EACrC,yBAAyB,GAAE,OAAe,QAmB7C"}
|