@geekmidas/cli 0.27.0 ā 0.28.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 +25 -16
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +25 -16
- package/dist/index.mjs.map +1 -1
- package/package.json +4 -4
- package/src/init/generators/models.ts +2 -11
- package/src/init/index.ts +15 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@geekmidas/cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.28.0",
|
|
4
4
|
"description": "CLI tools for building Lambda handlers, server applications, and generating OpenAPI specs",
|
|
5
5
|
"private": false,
|
|
6
6
|
"type": "module",
|
|
@@ -48,11 +48,11 @@
|
|
|
48
48
|
"lodash.kebabcase": "^4.1.1",
|
|
49
49
|
"openapi-typescript": "^7.4.2",
|
|
50
50
|
"prompts": "~2.4.2",
|
|
51
|
-
"@geekmidas/
|
|
52
|
-
"@geekmidas/schema": "~0.1.0",
|
|
51
|
+
"@geekmidas/logger": "~0.4.0",
|
|
53
52
|
"@geekmidas/errors": "~0.1.0",
|
|
54
53
|
"@geekmidas/envkit": "~0.4.0",
|
|
55
|
-
"@geekmidas/
|
|
54
|
+
"@geekmidas/constructs": "~0.6.0",
|
|
55
|
+
"@geekmidas/schema": "~0.1.0"
|
|
56
56
|
},
|
|
57
57
|
"devDependencies": {
|
|
58
58
|
"@types/lodash.kebabcase": "^4.1.9",
|
|
@@ -20,18 +20,9 @@ export function generateModelsPackage(
|
|
|
20
20
|
private: true,
|
|
21
21
|
type: 'module',
|
|
22
22
|
exports: {
|
|
23
|
-
'
|
|
24
|
-
types: './dist/index.d.ts',
|
|
25
|
-
import: './dist/index.js',
|
|
26
|
-
},
|
|
27
|
-
'./*': {
|
|
28
|
-
types: './dist/*.d.ts',
|
|
29
|
-
import: './dist/*.js',
|
|
30
|
-
},
|
|
23
|
+
'./*': './src/*.ts',
|
|
31
24
|
},
|
|
32
25
|
scripts: {
|
|
33
|
-
build: 'tsc',
|
|
34
|
-
'build:watch': 'tsc --watch',
|
|
35
26
|
typecheck: 'tsc --noEmit',
|
|
36
27
|
},
|
|
37
28
|
dependencies: {
|
|
@@ -42,7 +33,7 @@ export function generateModelsPackage(
|
|
|
42
33
|
},
|
|
43
34
|
};
|
|
44
35
|
|
|
45
|
-
// tsconfig.json for models -
|
|
36
|
+
// tsconfig.json for models - extends root config
|
|
46
37
|
const tsConfig = {
|
|
47
38
|
extends: '../../tsconfig.json',
|
|
48
39
|
compilerOptions: {
|
package/src/init/index.ts
CHANGED
|
@@ -395,6 +395,21 @@ export async function initCommand(
|
|
|
395
395
|
}
|
|
396
396
|
}
|
|
397
397
|
|
|
398
|
+
// Initialize git repository
|
|
399
|
+
console.log('\nš¦ Initializing git repository...\n');
|
|
400
|
+
try {
|
|
401
|
+
execSync('git init', { cwd: targetDir, stdio: 'pipe' });
|
|
402
|
+
execSync('git branch -M main', { cwd: targetDir, stdio: 'pipe' });
|
|
403
|
+
execSync('git add .', { cwd: targetDir, stdio: 'pipe' });
|
|
404
|
+
execSync('git commit -m "š Project created with @geekmidas/toolbox"', {
|
|
405
|
+
cwd: targetDir,
|
|
406
|
+
stdio: 'pipe',
|
|
407
|
+
});
|
|
408
|
+
console.log(' Initialized git repository on branch main');
|
|
409
|
+
} catch {
|
|
410
|
+
console.log(' Could not initialize git repository (git may not be installed)');
|
|
411
|
+
}
|
|
412
|
+
|
|
398
413
|
// Print success message with next steps
|
|
399
414
|
printNextSteps(name, templateOptions, pkgManager);
|
|
400
415
|
}
|