@willbooster/shared-lib-node 2.7.2 → 2.8.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/dist/cjs/hash.cjs CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";var e=require("node:crypto"),t=require("node:fs"),s=require("node:path");async function a(...a){const r=e.createHash("sha512");for(const e of a.sort()){const a=await t.promises.stat(e);if(a.isDirectory()){const a=await t.promises.readdir(e,{withFileTypes:!0,recursive:!0});for(const e of a.sort(((e,t)=>e.name.localeCompare(t.name))))e.isFile()&&r.update(await t.promises.readFile(s.join(e.path,e.name),"utf8"))}else a.isFile()&&r.update(await t.promises.readFile(e,"utf8"))}return r.digest("hex")}exports.calculateHashFromFiles=a,exports.updateHashFromFiles=async function(e,...s){let r="";try{r=await t.promises.readFile(e,"utf8")}catch{}const i=await a(...s);return r!==i&&(await t.promises.writeFile(e,i,"utf8"),!0)};
1
+ "use strict";var e=require("node:crypto"),t=require("node:fs"),s=require("node:path");async function r(e,...s){let r="";try{r=await t.promises.readFile(e,"utf8")}catch{}const i=await a(...s);return r!==i&&(await t.promises.writeFile(e,i,"utf8"),!0)}async function a(...r){const a=e.createHash("sha512");for(const e of r.sort()){const r=await t.promises.stat(e);if(r.isDirectory()){const r=await t.promises.readdir(e,{withFileTypes:!0,recursive:!0});for(const e of r.sort(((e,t)=>e.name.localeCompare(t.name))))e.isFile()&&a.update(await t.promises.readFile(s.join(e.path,e.name),"utf8"))}else r.isFile()&&a.update(await t.promises.readFile(e,"utf8"))}return a.digest("hex")}exports.calculateHashFromFiles=a,exports.canSkipSeed=async function(e,...t){return("1"===process.env.ALLOW_TO_SKIP_SEED||"true"===process.env.ALLOW_TO_SKIP_SEED)&&await r(e,...t)},exports.updateHashFromFiles=r;
2
2
  //# sourceMappingURL=hash.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"hash.cjs","sources":["../../src/hash.ts"],"sourcesContent":["import crypto from 'node:crypto';\nimport fs from 'node:fs';\nimport path from 'node:path';\n\n/**\n * Calculate hash from files.\n * @param paths Paths to the files or directories.\n * @returns Hash string.\n */\nexport async function calculateHashFromFiles(...paths: string[]): Promise<string> {\n const hash = crypto.createHash('sha512');\n for (const fileOrDirPath of paths.sort()) {\n const stat = await fs.promises.stat(fileOrDirPath);\n if (stat.isDirectory()) {\n // Get all files in the directory\n const dirents = await fs.promises.readdir(fileOrDirPath, { withFileTypes: true, recursive: true });\n for (const dirent of dirents.sort((d1, d2) => d1.name.localeCompare(d2.name))) {\n if (dirent.isFile()) {\n // Node.js 18.17.0 or later has `dirent.path`\n hash.update(\n await fs.promises.readFile(\n path.join((dirent as unknown as Record<'path', string>).path, dirent.name),\n 'utf8'\n )\n );\n }\n }\n } else if (stat.isFile()) {\n hash.update(await fs.promises.readFile(fileOrDirPath, 'utf8'));\n }\n }\n return hash.digest('hex');\n}\n\n/**\n * Update hash file if the hash is different from the current one.\n * @param hashFilePath Path to the hash file.\n * @param paths Paths to the files or directories.\n * @returns Whether the hash file was updated.\n */\nexport async function updateHashFromFiles(hashFilePath: string, ...paths: string[]): Promise<boolean> {\n let oldHash = '';\n try {\n oldHash = await fs.promises.readFile(hashFilePath, 'utf8');\n } catch {\n // do nothing\n }\n const newHash = await calculateHashFromFiles(...paths);\n if (oldHash === newHash) return false;\n\n await fs.promises.writeFile(hashFilePath, newHash, 'utf8');\n return true;\n}\n"],"names":["async","calculateHashFromFiles","paths","hash","crypto","createHash","fileOrDirPath","sort","stat","fs","promises","isDirectory","dirents","readdir","withFileTypes","recursive","dirent","d1","d2","name","localeCompare","isFile","update","readFile","path","join","digest","hashFilePath","oldHash","newHash","writeFile"],"mappings":"sFASOA,eAAeC,KAA0BC,GAC9C,MAAMC,EAAOC,EAAOC,WAAW,UAC/B,IAAK,MAAMC,KAAiBJ,EAAMK,OAAQ,CACxC,MAAMC,QAAaC,EAAGC,SAASF,KAAKF,GACpC,GAAIE,EAAKG,cAAe,CAEtB,MAAMC,QAAgBH,EAAGC,SAASG,QAAQP,EAAe,CAAEQ,eAAe,EAAMC,WAAW,IAC3F,IAAK,MAAMC,KAAUJ,EAAQL,MAAK,CAACU,EAAIC,IAAOD,EAAGE,KAAKC,cAAcF,EAAGC,QACjEH,EAAOK,UAETlB,EAAKmB,aACGb,EAAGC,SAASa,SAChBC,EAAKC,KAAMT,EAA6CQ,KAAMR,EAAOG,MACrE,QAKV,MAAWX,EAAKa,UACdlB,EAAKmB,aAAab,EAAGC,SAASa,SAASjB,EAAe,QAE1D,CACA,OAAOH,EAAKuB,OAAO,MACrB,8DAQO1B,eAAmC2B,KAAyBzB,GACjE,IAAI0B,EAAU,GACd,IACEA,QAAgBnB,EAAGC,SAASa,SAASI,EAAc,OACrD,CAAE,MACA,CAEF,MAAME,QAAgB5B,KAA0BC,GAChD,OAAI0B,IAAYC,UAEVpB,EAAGC,SAASoB,UAAUH,EAAcE,EAAS,SAC5C,EACT"}
1
+ {"version":3,"file":"hash.cjs","sources":["../../src/hash.ts"],"sourcesContent":["import crypto from 'node:crypto';\nimport fs from 'node:fs';\nimport path from 'node:path';\n\n/**\n * Check whether seed command can be skipped or not and update hash file if needed.\n * Note that process.env.ALLOW_TO_SKIP_SEED should be set to '1' or 'true' to skip seed.\n * @param hashFilePath Path to the hash file.\n * @param paths Paths to the files or directories.\n * @returns Whether seed command can be skipped.\n */\nexport async function canSkipSeed(hashFilePath: string, ...paths: string[]): Promise<boolean> {\n if (process.env.ALLOW_TO_SKIP_SEED !== '1' && process.env.ALLOW_TO_SKIP_SEED !== 'true') return false;\n return await updateHashFromFiles(hashFilePath, ...paths);\n}\n\n/**\n * Update hash file if the hash is different from the current one.\n * @param hashFilePath Path to the hash file.\n * @param paths Paths to the files or directories.\n * @returns Whether the hash file was updated.\n */\nexport async function updateHashFromFiles(hashFilePath: string, ...paths: string[]): Promise<boolean> {\n let oldHash = '';\n try {\n oldHash = await fs.promises.readFile(hashFilePath, 'utf8');\n } catch {\n // do nothing\n }\n const newHash = await calculateHashFromFiles(...paths);\n if (oldHash === newHash) return false;\n\n await fs.promises.writeFile(hashFilePath, newHash, 'utf8');\n return true;\n}\n\n/**\n * Calculate hash from files.\n * @param paths Paths to the files or directories.\n * @returns Hash string.\n */\nexport async function calculateHashFromFiles(...paths: string[]): Promise<string> {\n const hash = crypto.createHash('sha512');\n for (const fileOrDirPath of paths.sort()) {\n const stat = await fs.promises.stat(fileOrDirPath);\n if (stat.isDirectory()) {\n // Get all files in the directory\n const dirents = await fs.promises.readdir(fileOrDirPath, { withFileTypes: true, recursive: true });\n for (const dirent of dirents.sort((d1, d2) => d1.name.localeCompare(d2.name))) {\n if (dirent.isFile()) {\n // Node.js 18.17.0 or later has `dirent.path`\n hash.update(\n await fs.promises.readFile(\n path.join((dirent as unknown as Record<'path', string>).path, dirent.name),\n 'utf8'\n )\n );\n }\n }\n } else if (stat.isFile()) {\n hash.update(await fs.promises.readFile(fileOrDirPath, 'utf8'));\n }\n }\n return hash.digest('hex');\n}\n"],"names":["async","updateHashFromFiles","hashFilePath","paths","oldHash","fs","promises","readFile","newHash","calculateHashFromFiles","writeFile","hash","crypto","createHash","fileOrDirPath","sort","stat","isDirectory","dirents","readdir","withFileTypes","recursive","dirent","d1","d2","name","localeCompare","isFile","update","path","join","digest","process","env","ALLOW_TO_SKIP_SEED"],"mappings":"sFAsBOA,eAAeC,EAAoBC,KAAyBC,GACjE,IAAIC,EAAU,GACd,IACEA,QAAgBC,EAAGC,SAASC,SAASL,EAAc,OACrD,CAAE,MACA,CAEF,MAAMM,QAAgBC,KAA0BN,GAChD,OAAIC,IAAYI,UAEVH,EAAGC,SAASI,UAAUR,EAAcM,EAAS,SAC5C,EACT,CAOOR,eAAeS,KAA0BN,GAC9C,MAAMQ,EAAOC,EAAOC,WAAW,UAC/B,IAAK,MAAMC,KAAiBX,EAAMY,OAAQ,CACxC,MAAMC,QAAaX,EAAGC,SAASU,KAAKF,GACpC,GAAIE,EAAKC,cAAe,CAEtB,MAAMC,QAAgBb,EAAGC,SAASa,QAAQL,EAAe,CAAEM,eAAe,EAAMC,WAAW,IAC3F,IAAK,MAAMC,KAAUJ,EAAQH,MAAK,CAACQ,EAAIC,IAAOD,EAAGE,KAAKC,cAAcF,EAAGC,QACjEH,EAAOK,UAEThB,EAAKiB,aACGvB,EAAGC,SAASC,SAChBsB,EAAKC,KAAMR,EAA6CO,KAAMP,EAAOG,MACrE,QAKV,MAAWT,EAAKW,UACdhB,EAAKiB,aAAavB,EAAGC,SAASC,SAASO,EAAe,QAE1D,CACA,OAAOH,EAAKoB,OAAO,MACrB,sDArDO/B,eAA2BE,KAAyBC,GACzD,OAAuC,MAAnC6B,QAAQC,IAAIC,oBAAiE,SAAnCF,QAAQC,IAAIC,2BAC7CjC,EAAoBC,KAAiBC,EACpD"}
@@ -1,9 +1,11 @@
1
1
  /**
2
- * Calculate hash from files.
2
+ * Check whether seed command can be skipped or not and update hash file if needed.
3
+ * Note that process.env.ALLOW_TO_SKIP_SEED should be set to '1' or 'true' to skip seed.
4
+ * @param hashFilePath Path to the hash file.
3
5
  * @param paths Paths to the files or directories.
4
- * @returns Hash string.
6
+ * @returns Whether seed command can be skipped.
5
7
  */
6
- declare function calculateHashFromFiles(...paths: string[]): Promise<string>;
8
+ declare function canSkipSeed(hashFilePath: string, ...paths: string[]): Promise<boolean>;
7
9
  /**
8
10
  * Update hash file if the hash is different from the current one.
9
11
  * @param hashFilePath Path to the hash file.
@@ -11,4 +13,10 @@ declare function calculateHashFromFiles(...paths: string[]): Promise<string>;
11
13
  * @returns Whether the hash file was updated.
12
14
  */
13
15
  declare function updateHashFromFiles(hashFilePath: string, ...paths: string[]): Promise<boolean>;
14
- export { calculateHashFromFiles, updateHashFromFiles };
16
+ /**
17
+ * Calculate hash from files.
18
+ * @param paths Paths to the files or directories.
19
+ * @returns Hash string.
20
+ */
21
+ declare function calculateHashFromFiles(...paths: string[]): Promise<string>;
22
+ export { canSkipSeed, updateHashFromFiles, calculateHashFromFiles };
@@ -1,2 +1,2 @@
1
- "use strict";var s=require("./env.cjs"),e=require("./exists.cjs"),r=require("./hash.cjs"),a=require("./spawn.cjs");exports.loadEnvironmentVariables=s.loadEnvironmentVariables,exports.removeNpmAndYarnEnvironmentVariables=s.removeNpmAndYarnEnvironmentVariables,exports.yargsOptionsBuilderForEnv=s.yargsOptionsBuilderForEnv,exports.existsAsync=e.existsAsync,exports.calculateHashFromFiles=r.calculateHashFromFiles,exports.updateHashFromFiles=r.updateHashFromFiles,exports.spawnAsync=a.spawnAsync;
1
+ "use strict";var e=require("./env.cjs"),s=require("./exists.cjs"),r=require("./hash.cjs"),a=require("./spawn.cjs");exports.loadEnvironmentVariables=e.loadEnvironmentVariables,exports.removeNpmAndYarnEnvironmentVariables=e.removeNpmAndYarnEnvironmentVariables,exports.yargsOptionsBuilderForEnv=e.yargsOptionsBuilderForEnv,exports.existsAsync=s.existsAsync,exports.calculateHashFromFiles=r.calculateHashFromFiles,exports.canSkipSeed=r.canSkipSeed,exports.updateHashFromFiles=r.updateHashFromFiles,exports.spawnAsync=a.spawnAsync;
2
2
  //# sourceMappingURL=index.cjs.map
@@ -1,4 +1,4 @@
1
1
  export { loadEnvironmentVariables, removeNpmAndYarnEnvironmentVariables, yargsOptionsBuilderForEnv } from "./env.js";
2
2
  export { existsAsync } from "./exists.js";
3
- export { calculateHashFromFiles, updateHashFromFiles } from "./hash.js";
3
+ export { calculateHashFromFiles, canSkipSeed, updateHashFromFiles } from "./hash.js";
4
4
  export { spawnAsync } from "./spawn.js";
@@ -1,9 +1,11 @@
1
1
  /**
2
- * Calculate hash from files.
2
+ * Check whether seed command can be skipped or not and update hash file if needed.
3
+ * Note that process.env.ALLOW_TO_SKIP_SEED should be set to '1' or 'true' to skip seed.
4
+ * @param hashFilePath Path to the hash file.
3
5
  * @param paths Paths to the files or directories.
4
- * @returns Hash string.
6
+ * @returns Whether seed command can be skipped.
5
7
  */
6
- declare function calculateHashFromFiles(...paths: string[]): Promise<string>;
8
+ declare function canSkipSeed(hashFilePath: string, ...paths: string[]): Promise<boolean>;
7
9
  /**
8
10
  * Update hash file if the hash is different from the current one.
9
11
  * @param hashFilePath Path to the hash file.
@@ -11,4 +13,10 @@ declare function calculateHashFromFiles(...paths: string[]): Promise<string>;
11
13
  * @returns Whether the hash file was updated.
12
14
  */
13
15
  declare function updateHashFromFiles(hashFilePath: string, ...paths: string[]): Promise<boolean>;
14
- export { calculateHashFromFiles, updateHashFromFiles };
16
+ /**
17
+ * Calculate hash from files.
18
+ * @param paths Paths to the files or directories.
19
+ * @returns Hash string.
20
+ */
21
+ declare function calculateHashFromFiles(...paths: string[]): Promise<string>;
22
+ export { canSkipSeed, updateHashFromFiles, calculateHashFromFiles };
package/dist/esm/hash.js CHANGED
@@ -1,2 +1,2 @@
1
- import e from"node:crypto";import t from"node:fs";import i from"node:path";async function o(...o){const r=e.createHash("sha512");for(const e of o.sort()){const o=await t.promises.stat(e);if(o.isDirectory()){const o=await t.promises.readdir(e,{withFileTypes:!0,recursive:!0});for(const e of o.sort(((e,t)=>e.name.localeCompare(t.name))))e.isFile()&&r.update(await t.promises.readFile(i.join(e.path,e.name),"utf8"))}else o.isFile()&&r.update(await t.promises.readFile(e,"utf8"))}return r.digest("hex")}async function r(e,...i){let r="";try{r=await t.promises.readFile(e,"utf8")}catch{}const a=await o(...i);return r!==a&&(await t.promises.writeFile(e,a,"utf8"),!0)}export{o as calculateHashFromFiles,r as updateHashFromFiles};
1
+ import e from"node:crypto";import t from"node:fs";import r from"node:path";async function i(e,...t){return("1"===process.env.ALLOW_TO_SKIP_SEED||"true"===process.env.ALLOW_TO_SKIP_SEED)&&await o(e,...t)}async function o(e,...r){let i="";try{i=await t.promises.readFile(e,"utf8")}catch{}const o=await s(...r);return i!==o&&(await t.promises.writeFile(e,o,"utf8"),!0)}async function s(...i){const o=e.createHash("sha512");for(const e of i.sort()){const i=await t.promises.stat(e);if(i.isDirectory()){const i=await t.promises.readdir(e,{withFileTypes:!0,recursive:!0});for(const e of i.sort(((e,t)=>e.name.localeCompare(t.name))))e.isFile()&&o.update(await t.promises.readFile(r.join(e.path,e.name),"utf8"))}else i.isFile()&&o.update(await t.promises.readFile(e,"utf8"))}return o.digest("hex")}export{s as calculateHashFromFiles,i as canSkipSeed,o as updateHashFromFiles};
2
2
  //# sourceMappingURL=hash.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"hash.js","sources":["../../src/hash.ts"],"sourcesContent":["import crypto from 'node:crypto';\nimport fs from 'node:fs';\nimport path from 'node:path';\n\n/**\n * Calculate hash from files.\n * @param paths Paths to the files or directories.\n * @returns Hash string.\n */\nexport async function calculateHashFromFiles(...paths: string[]): Promise<string> {\n const hash = crypto.createHash('sha512');\n for (const fileOrDirPath of paths.sort()) {\n const stat = await fs.promises.stat(fileOrDirPath);\n if (stat.isDirectory()) {\n // Get all files in the directory\n const dirents = await fs.promises.readdir(fileOrDirPath, { withFileTypes: true, recursive: true });\n for (const dirent of dirents.sort((d1, d2) => d1.name.localeCompare(d2.name))) {\n if (dirent.isFile()) {\n // Node.js 18.17.0 or later has `dirent.path`\n hash.update(\n await fs.promises.readFile(\n path.join((dirent as unknown as Record<'path', string>).path, dirent.name),\n 'utf8'\n )\n );\n }\n }\n } else if (stat.isFile()) {\n hash.update(await fs.promises.readFile(fileOrDirPath, 'utf8'));\n }\n }\n return hash.digest('hex');\n}\n\n/**\n * Update hash file if the hash is different from the current one.\n * @param hashFilePath Path to the hash file.\n * @param paths Paths to the files or directories.\n * @returns Whether the hash file was updated.\n */\nexport async function updateHashFromFiles(hashFilePath: string, ...paths: string[]): Promise<boolean> {\n let oldHash = '';\n try {\n oldHash = await fs.promises.readFile(hashFilePath, 'utf8');\n } catch {\n // do nothing\n }\n const newHash = await calculateHashFromFiles(...paths);\n if (oldHash === newHash) return false;\n\n await fs.promises.writeFile(hashFilePath, newHash, 'utf8');\n return true;\n}\n"],"names":["async","calculateHashFromFiles","paths","hash","crypto","createHash","fileOrDirPath","sort","stat","fs","promises","isDirectory","dirents","readdir","withFileTypes","recursive","dirent","d1","d2","name","localeCompare","isFile","update","readFile","path","join","digest","updateHashFromFiles","hashFilePath","oldHash","newHash","writeFile"],"mappings":"2EASOA,eAAeC,KAA0BC,GAC9C,MAAMC,EAAOC,EAAOC,WAAW,UAC/B,IAAK,MAAMC,KAAiBJ,EAAMK,OAAQ,CACxC,MAAMC,QAAaC,EAAGC,SAASF,KAAKF,GACpC,GAAIE,EAAKG,cAAe,CAEtB,MAAMC,QAAgBH,EAAGC,SAASG,QAAQP,EAAe,CAAEQ,eAAe,EAAMC,WAAW,IAC3F,IAAK,MAAMC,KAAUJ,EAAQL,MAAK,CAACU,EAAIC,IAAOD,EAAGE,KAAKC,cAAcF,EAAGC,QACjEH,EAAOK,UAETlB,EAAKmB,aACGb,EAAGC,SAASa,SAChBC,EAAKC,KAAMT,EAA6CQ,KAAMR,EAAOG,MACrE,QAKV,MAAWX,EAAKa,UACdlB,EAAKmB,aAAab,EAAGC,SAASa,SAASjB,EAAe,QAE1D,CACA,OAAOH,EAAKuB,OAAO,MACrB,CAQO1B,eAAe2B,EAAoBC,KAAyB1B,GACjE,IAAI2B,EAAU,GACd,IACEA,QAAgBpB,EAAGC,SAASa,SAASK,EAAc,OACrD,CAAE,MACA,CAEF,MAAME,QAAgB7B,KAA0BC,GAChD,OAAI2B,IAAYC,UAEVrB,EAAGC,SAASqB,UAAUH,EAAcE,EAAS,SAC5C,EACT"}
1
+ {"version":3,"file":"hash.js","sources":["../../src/hash.ts"],"sourcesContent":["import crypto from 'node:crypto';\nimport fs from 'node:fs';\nimport path from 'node:path';\n\n/**\n * Check whether seed command can be skipped or not and update hash file if needed.\n * Note that process.env.ALLOW_TO_SKIP_SEED should be set to '1' or 'true' to skip seed.\n * @param hashFilePath Path to the hash file.\n * @param paths Paths to the files or directories.\n * @returns Whether seed command can be skipped.\n */\nexport async function canSkipSeed(hashFilePath: string, ...paths: string[]): Promise<boolean> {\n if (process.env.ALLOW_TO_SKIP_SEED !== '1' && process.env.ALLOW_TO_SKIP_SEED !== 'true') return false;\n return await updateHashFromFiles(hashFilePath, ...paths);\n}\n\n/**\n * Update hash file if the hash is different from the current one.\n * @param hashFilePath Path to the hash file.\n * @param paths Paths to the files or directories.\n * @returns Whether the hash file was updated.\n */\nexport async function updateHashFromFiles(hashFilePath: string, ...paths: string[]): Promise<boolean> {\n let oldHash = '';\n try {\n oldHash = await fs.promises.readFile(hashFilePath, 'utf8');\n } catch {\n // do nothing\n }\n const newHash = await calculateHashFromFiles(...paths);\n if (oldHash === newHash) return false;\n\n await fs.promises.writeFile(hashFilePath, newHash, 'utf8');\n return true;\n}\n\n/**\n * Calculate hash from files.\n * @param paths Paths to the files or directories.\n * @returns Hash string.\n */\nexport async function calculateHashFromFiles(...paths: string[]): Promise<string> {\n const hash = crypto.createHash('sha512');\n for (const fileOrDirPath of paths.sort()) {\n const stat = await fs.promises.stat(fileOrDirPath);\n if (stat.isDirectory()) {\n // Get all files in the directory\n const dirents = await fs.promises.readdir(fileOrDirPath, { withFileTypes: true, recursive: true });\n for (const dirent of dirents.sort((d1, d2) => d1.name.localeCompare(d2.name))) {\n if (dirent.isFile()) {\n // Node.js 18.17.0 or later has `dirent.path`\n hash.update(\n await fs.promises.readFile(\n path.join((dirent as unknown as Record<'path', string>).path, dirent.name),\n 'utf8'\n )\n );\n }\n }\n } else if (stat.isFile()) {\n hash.update(await fs.promises.readFile(fileOrDirPath, 'utf8'));\n }\n }\n return hash.digest('hex');\n}\n"],"names":["async","canSkipSeed","hashFilePath","paths","process","env","ALLOW_TO_SKIP_SEED","updateHashFromFiles","oldHash","fs","promises","readFile","newHash","calculateHashFromFiles","writeFile","hash","crypto","createHash","fileOrDirPath","sort","stat","isDirectory","dirents","readdir","withFileTypes","recursive","dirent","d1","d2","name","localeCompare","isFile","update","path","join","digest"],"mappings":"2EAWOA,eAAeC,EAAYC,KAAyBC,GACzD,OAAuC,MAAnCC,QAAQC,IAAIC,oBAAiE,SAAnCF,QAAQC,IAAIC,2BAC7CC,EAAoBL,KAAiBC,EACpD,CAQOH,eAAeO,EAAoBL,KAAyBC,GACjE,IAAIK,EAAU,GACd,IACEA,QAAgBC,EAAGC,SAASC,SAAST,EAAc,OACrD,CAAE,MACA,CAEF,MAAMU,QAAgBC,KAA0BV,GAChD,OAAIK,IAAYI,UAEVH,EAAGC,SAASI,UAAUZ,EAAcU,EAAS,SAC5C,EACT,CAOOZ,eAAea,KAA0BV,GAC9C,MAAMY,EAAOC,EAAOC,WAAW,UAC/B,IAAK,MAAMC,KAAiBf,EAAMgB,OAAQ,CACxC,MAAMC,QAAaX,EAAGC,SAASU,KAAKF,GACpC,GAAIE,EAAKC,cAAe,CAEtB,MAAMC,QAAgBb,EAAGC,SAASa,QAAQL,EAAe,CAAEM,eAAe,EAAMC,WAAW,IAC3F,IAAK,MAAMC,KAAUJ,EAAQH,MAAK,CAACQ,EAAIC,IAAOD,EAAGE,KAAKC,cAAcF,EAAGC,QACjEH,EAAOK,UAEThB,EAAKiB,aACGvB,EAAGC,SAASC,SAChBsB,EAAKC,KAAMR,EAA6CO,KAAMP,EAAOG,MACrE,QAKV,MAAWT,EAAKW,UACdhB,EAAKiB,aAAavB,EAAGC,SAASC,SAASO,EAAe,QAE1D,CACA,OAAOH,EAAKoB,OAAO,MACrB"}
@@ -1,4 +1,4 @@
1
1
  export { loadEnvironmentVariables, removeNpmAndYarnEnvironmentVariables, yargsOptionsBuilderForEnv } from "./env.js";
2
2
  export { existsAsync } from "./exists.js";
3
- export { calculateHashFromFiles, updateHashFromFiles } from "./hash.js";
3
+ export { calculateHashFromFiles, canSkipSeed, updateHashFromFiles } from "./hash.js";
4
4
  export { spawnAsync } from "./spawn.js";
package/dist/esm/index.js CHANGED
@@ -1,2 +1,2 @@
1
- export{loadEnvironmentVariables,removeNpmAndYarnEnvironmentVariables,yargsOptionsBuilderForEnv}from"./env.js";export{existsAsync}from"./exists.js";export{calculateHashFromFiles,updateHashFromFiles}from"./hash.js";export{spawnAsync}from"./spawn.js";
1
+ export{loadEnvironmentVariables,removeNpmAndYarnEnvironmentVariables,yargsOptionsBuilderForEnv}from"./env.js";export{existsAsync}from"./exists.js";export{calculateHashFromFiles,canSkipSeed,updateHashFromFiles}from"./hash.js";export{spawnAsync}from"./spawn.js";
2
2
  //# sourceMappingURL=index.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@willbooster/shared-lib-node",
3
- "version": "2.7.2",
3
+ "version": "2.8.0",
4
4
  "license": "Apache-2.0",
5
5
  "author": "WillBooster Inc.",
6
6
  "sideEffects": false,
@@ -40,18 +40,18 @@
40
40
  "tree-kill": "1.2.2"
41
41
  },
42
42
  "devDependencies": {
43
- "@types/eslint": "8.44.1",
43
+ "@types/eslint": "8.44.2",
44
44
  "@types/micromatch": "4.0.2",
45
- "@types/node": "18.17.2",
45
+ "@types/node": "18.17.5",
46
46
  "@types/prettier": "2.7.3",
47
- "@typescript-eslint/eslint-plugin": "6.2.1",
48
- "@typescript-eslint/parser": "6.2.1",
47
+ "@typescript-eslint/eslint-plugin": "6.3.0",
48
+ "@typescript-eslint/parser": "6.3.0",
49
49
  "@willbooster/eslint-config-ts": "10.4.0",
50
50
  "@willbooster/prettier-config": "9.1.1",
51
- "build-ts": "8.2.0",
52
- "eslint": "8.46.0",
53
- "eslint-config-prettier": "8.10.0",
54
- "eslint-import-resolver-typescript": "3.5.5",
51
+ "build-ts": "8.2.1",
52
+ "eslint": "8.47.0",
53
+ "eslint-config-prettier": "9.0.0",
54
+ "eslint-import-resolver-typescript": "3.6.0",
55
55
  "eslint-plugin-import": "2.28.0",
56
56
  "eslint-plugin-sort-class-members": "1.18.0",
57
57
  "eslint-plugin-sort-destructure-keys": "1.5.0",