@karmaniverous/get-dotenv 7.0.7 → 7.0.9
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/chunks/{createCli-DRgcaM2D.mjs → createCli-CCxTLJ1j.mjs} +57 -10
- package/dist/chunks/index-Cay5Gzhu.mjs +111 -0
- package/dist/chunks/{index-BzoCat8h.mjs → index-xqvxTkr9.mjs} +6 -6
- package/dist/chunks/{loader-V1vbmtyw.mjs → loader-C3DtD6HB.mjs} +4 -2
- package/dist/chunks/{readDotenvCascade-Dgx4SC1p.mjs → readDotenvCascade-CfFPgLCp.mjs} +52 -21
- package/dist/chunks/{readMergedOptions-x80ltQO_.mjs → readMergedOptions-_hjyCNZ7.mjs} +54 -14
- package/dist/chunks/{resolveCliOptions-CR-BEUmS.mjs → resolveCliOptions-Dp7wPY1K.mjs} +1 -1
- package/dist/chunks/{spawnEnv-CKgnHGpr.mjs → spawnEnv-DvisqPiU.mjs} +28 -3
- package/dist/chunks/{types-poB1VAs_.mjs → types-zXDNhcST.mjs} +1 -1
- package/dist/cli.d.ts +9 -5
- package/dist/cli.mjs +10 -15
- package/dist/cliHost.d.ts +9 -5
- package/dist/cliHost.mjs +6 -6
- package/dist/config.d.ts +1 -1
- package/dist/config.mjs +1 -1
- package/dist/env-overlay.d.ts +13 -9
- package/dist/env-overlay.mjs +2 -2
- package/dist/getdotenv.cli.mjs +10 -15
- package/dist/index.d.ts +10 -6
- package/dist/index.mjs +30 -23
- package/dist/plugins-aws.d.ts +1 -1
- package/dist/plugins-aws.mjs +4 -4
- package/dist/plugins-batch.d.ts +17 -1
- package/dist/plugins-batch.mjs +202 -68
- package/dist/plugins-cmd.d.ts +1 -1
- package/dist/plugins-cmd.mjs +6 -6
- package/dist/plugins-init.d.ts +1 -1
- package/dist/plugins-init.mjs +3 -3
- package/dist/plugins.d.ts +3 -1
- package/dist/plugins.mjs +9 -14
- package/package.json +40 -40
- package/schema/getdotenv.config.schema.json +207 -0
- package/dist/chunks/AwsRestJsonProtocol-BWWvLZiw.mjs +0 -1026
- package/dist/chunks/externalDataInterceptor-Bbvq4sdd.mjs +0 -19
- package/dist/chunks/getSSOTokenFromFile-ClTzvS3i.mjs +0 -22
- package/dist/chunks/index-4kbkrHS9.mjs +0 -12529
- package/dist/chunks/index-B5GwHCSX.mjs +0 -669
- package/dist/chunks/index-Cl6wXPYD.mjs +0 -82
- package/dist/chunks/index-D7Lv-lxm.mjs +0 -349
- package/dist/chunks/index-DFNP_Nrx.mjs +0 -188
- package/dist/chunks/index-DO68RbZ8.mjs +0 -103
- package/dist/chunks/index-Db08BBL5.mjs +0 -519
- package/dist/chunks/index-De2jIOhi.mjs +0 -541
- package/dist/chunks/index-IOQ1o3w3.mjs +0 -290
- package/dist/chunks/index-Tm4WDj9R.mjs +0 -383
- package/dist/chunks/index-fNrNPp4e.mjs +0 -946
- package/dist/chunks/index-w8gK2SKP.mjs +0 -31
- package/dist/chunks/loadSso-Ce3ChPPj.mjs +0 -488
- package/dist/chunks/package-DbbYaehr.mjs +0 -5
- package/dist/chunks/parseKnownFiles-BCL0L7aP.mjs +0 -23
- package/dist/chunks/sdk-stream-mixin-B_ajKWho.mjs +0 -307
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { t as tokenIntercept } from './getSSOTokenFromFile-ClTzvS3i.mjs';
|
|
2
|
-
import { a4 as fileIntercept } from './index-4kbkrHS9.mjs';
|
|
3
|
-
|
|
4
|
-
const externalDataInterceptor = {
|
|
5
|
-
getFileRecord() {
|
|
6
|
-
return fileIntercept;
|
|
7
|
-
},
|
|
8
|
-
interceptFile(path, contents) {
|
|
9
|
-
fileIntercept[path] = Promise.resolve(contents);
|
|
10
|
-
},
|
|
11
|
-
getTokenRecord() {
|
|
12
|
-
return tokenIntercept;
|
|
13
|
-
},
|
|
14
|
-
interceptToken(id, contents) {
|
|
15
|
-
tokenIntercept[id] = contents;
|
|
16
|
-
},
|
|
17
|
-
};
|
|
18
|
-
|
|
19
|
-
export { externalDataInterceptor as e };
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { readFile } from 'node:fs/promises';
|
|
2
|
-
import { createHash } from 'node:crypto';
|
|
3
|
-
import { join } from 'node:path';
|
|
4
|
-
import { af as getHomeDir } from './index-4kbkrHS9.mjs';
|
|
5
|
-
|
|
6
|
-
const getSSOTokenFilepath = (id) => {
|
|
7
|
-
const hasher = createHash("sha1");
|
|
8
|
-
const cacheName = hasher.update(id).digest("hex");
|
|
9
|
-
return join(getHomeDir(), ".aws", "sso", "cache", `${cacheName}.json`);
|
|
10
|
-
};
|
|
11
|
-
|
|
12
|
-
const tokenIntercept = {};
|
|
13
|
-
const getSSOTokenFromFile = async (id) => {
|
|
14
|
-
if (tokenIntercept[id]) {
|
|
15
|
-
return tokenIntercept[id];
|
|
16
|
-
}
|
|
17
|
-
const ssoTokenFilepath = getSSOTokenFilepath(id);
|
|
18
|
-
const ssoTokenText = await readFile(ssoTokenFilepath, "utf8");
|
|
19
|
-
return JSON.parse(ssoTokenText);
|
|
20
|
-
};
|
|
21
|
-
|
|
22
|
-
export { getSSOTokenFromFile as a, getSSOTokenFilepath as g, tokenIntercept as t };
|