@geekmidas/cli 0.32.0 → 0.33.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/index.cjs +8 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +8 -4
- package/dist/index.mjs.map +1 -1
- package/package.json +4 -4
- package/src/dev/__tests__/entry.spec.ts +3 -3
- package/src/dev/index.ts +10 -2
- package/src/init/generators/auth.ts +2 -1
package/dist/index.mjs
CHANGED
|
@@ -26,7 +26,7 @@ import prompts from "prompts";
|
|
|
26
26
|
|
|
27
27
|
//#region package.json
|
|
28
28
|
var name = "@geekmidas/cli";
|
|
29
|
-
var version = "0.
|
|
29
|
+
var version = "0.33.0";
|
|
30
30
|
var description = "CLI tools for building Lambda handlers, server applications, and generating OpenAPI specs";
|
|
31
31
|
var private$1 = false;
|
|
32
32
|
var type = "module";
|
|
@@ -1557,8 +1557,8 @@ if (existsSync(secretsPath)) {
|
|
|
1557
1557
|
/**
|
|
1558
1558
|
* Entry wrapper generated by 'gkm dev --entry'
|
|
1559
1559
|
*/
|
|
1560
|
-
${credentialsInjection}// Import and run the user's entry file
|
|
1561
|
-
import
|
|
1560
|
+
${credentialsInjection}// Import and run the user's entry file (dynamic import ensures secrets load first)
|
|
1561
|
+
await import('${entryPath}');
|
|
1562
1562
|
`;
|
|
1563
1563
|
await writeFile(wrapperPath, content);
|
|
1564
1564
|
}
|
|
@@ -1575,9 +1575,12 @@ async function entryDevCommand(options) {
|
|
|
1575
1575
|
const defaultEnv = loadEnvFiles(".env");
|
|
1576
1576
|
if (defaultEnv.loaded.length > 0) logger$8.log(`📦 Loaded env: ${defaultEnv.loaded.join(", ")}`);
|
|
1577
1577
|
const secretsRoot = findSecretsRoot(process.cwd());
|
|
1578
|
+
logger$8.log(`🔍 Secrets root: ${secretsRoot}`);
|
|
1578
1579
|
const appName = getAppNameFromCwd() ?? void 0;
|
|
1580
|
+
if (appName) logger$8.log(`📦 App name: ${appName}`);
|
|
1579
1581
|
const appSecrets = await loadSecretsForApp(secretsRoot, appName);
|
|
1580
1582
|
if (Object.keys(appSecrets).length > 0) logger$8.log(`🔐 Loaded ${Object.keys(appSecrets).length} secret(s)`);
|
|
1583
|
+
else logger$8.log(`⚠️ No secrets found in ${secretsRoot}/.gkm/secrets/`);
|
|
1581
1584
|
let secretsJsonPath;
|
|
1582
1585
|
if (Object.keys(appSecrets).length > 0) {
|
|
1583
1586
|
const secretsDir = join(secretsRoot, ".gkm");
|
|
@@ -4521,7 +4524,7 @@ function generateAuthAppFiles(options) {
|
|
|
4521
4524
|
private: true,
|
|
4522
4525
|
type: "module",
|
|
4523
4526
|
scripts: {
|
|
4524
|
-
dev: "
|
|
4527
|
+
dev: "gkm dev --entry ./src/index.ts",
|
|
4525
4528
|
build: "tsc",
|
|
4526
4529
|
start: "node dist/index.js",
|
|
4527
4530
|
typecheck: "tsc --noEmit"
|
|
@@ -4537,6 +4540,7 @@ function generateAuthAppFiles(options) {
|
|
|
4537
4540
|
pg: "~8.13.0"
|
|
4538
4541
|
},
|
|
4539
4542
|
devDependencies: {
|
|
4543
|
+
"@geekmidas/cli": GEEKMIDAS_VERSIONS["@geekmidas/cli"],
|
|
4540
4544
|
"@types/node": "~22.0.0",
|
|
4541
4545
|
"@types/pg": "~8.11.0",
|
|
4542
4546
|
tsx: "~4.20.0",
|