@slingr/cli 0.0.3 → 0.0.4
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/LICENSE.txt +202 -0
- package/README.md +490 -319
- package/bin/dev.cmd +2 -2
- package/bin/dev.js +5 -5
- package/bin/run.cmd +2 -2
- package/bin/run.js +4 -4
- package/bin/slingr +1 -0
- package/dist/commands/build.d.ts +20 -0
- package/dist/commands/build.d.ts.map +1 -0
- package/dist/commands/build.js +206 -0
- package/dist/commands/build.js.map +1 -0
- package/dist/commands/create-app.d.ts +0 -1
- package/dist/commands/create-app.d.ts.map +1 -1
- package/dist/commands/create-app.js +38 -57
- package/dist/commands/create-app.js.map +1 -1
- package/dist/commands/debug.d.ts +28 -0
- package/dist/commands/debug.d.ts.map +1 -0
- package/dist/commands/debug.js +474 -0
- package/dist/commands/debug.js.map +1 -0
- package/dist/commands/ds.d.ts +14 -1
- package/dist/commands/ds.d.ts.map +1 -1
- package/dist/commands/ds.js +450 -121
- package/dist/commands/ds.js.map +1 -1
- package/dist/commands/gql.d.ts +1 -1
- package/dist/commands/gql.d.ts.map +1 -1
- package/dist/commands/gql.js +190 -184
- package/dist/commands/gql.js.map +1 -1
- package/dist/commands/infra/down.d.ts.map +1 -1
- package/dist/commands/infra/down.js +8 -7
- package/dist/commands/infra/down.js.map +1 -1
- package/dist/commands/infra/up.d.ts.map +1 -1
- package/dist/commands/infra/up.js +8 -7
- package/dist/commands/infra/up.js.map +1 -1
- package/dist/commands/infra/update.d.ts +1 -0
- package/dist/commands/infra/update.d.ts.map +1 -1
- package/dist/commands/infra/update.js +33 -69
- package/dist/commands/infra/update.js.map +1 -1
- package/dist/commands/run.d.ts +29 -2
- package/dist/commands/run.d.ts.map +1 -1
- package/dist/commands/run.js +628 -130
- package/dist/commands/run.js.map +1 -1
- package/dist/commands/setup.d.ts +1 -1
- package/dist/commands/setup.d.ts.map +1 -1
- package/dist/commands/setup.js +34 -71
- package/dist/commands/setup.js.map +1 -1
- package/dist/commands/sync-metadata.d.ts +15 -0
- package/dist/commands/sync-metadata.d.ts.map +1 -0
- package/dist/commands/sync-metadata.js +225 -0
- package/dist/commands/sync-metadata.js.map +1 -0
- package/dist/commands/users.d.ts +30 -0
- package/dist/commands/users.d.ts.map +1 -0
- package/dist/commands/users.js +472 -0
- package/dist/commands/users.js.map +1 -0
- package/dist/commands/views.d.ts +11 -0
- package/dist/commands/views.d.ts.map +1 -0
- package/dist/commands/views.js +73 -0
- package/dist/commands/views.js.map +1 -0
- package/dist/projectStructure.d.ts +2 -2
- package/dist/projectStructure.d.ts.map +1 -1
- package/dist/projectStructure.js +281 -69
- package/dist/projectStructure.js.map +1 -1
- package/dist/scripts/generate-metadata.d.ts +13 -0
- package/dist/scripts/generate-metadata.d.ts.map +1 -0
- package/dist/scripts/generate-metadata.js +412 -0
- package/dist/scripts/generate-metadata.js.map +1 -0
- package/dist/scripts/generate-metadata.ts +498 -0
- package/dist/scripts/generate-schema.d.ts +1 -1
- package/dist/scripts/generate-schema.js +168 -74
- package/dist/scripts/generate-schema.js.map +1 -1
- package/dist/scripts/generate-schema.ts +258 -143
- package/dist/templates/.env.template +23 -0
- package/dist/templates/.firebaserc.template +5 -0
- package/dist/templates/.github/copilot-instructions.md.template +652 -17
- package/dist/templates/backend/Dockerfile.template +30 -0
- package/dist/templates/config/datasource.ts.template +12 -9
- package/dist/templates/config/jest.config.ts +30 -30
- package/dist/templates/config/jest.setup.ts +1 -1
- package/dist/templates/config/tsconfig.json.template +50 -29
- package/dist/templates/dataSources/mysql.ts.template +16 -13
- package/dist/templates/dataSources/postgres.ts.template +15 -13
- package/dist/templates/dataset-generator-script.ts.template +139 -139
- package/dist/templates/datasets/mysql-default/.slingr-schema.json.template +5 -0
- package/dist/templates/datasets/mysql-default/Address.jsonl.template +3 -3
- package/dist/templates/datasets/mysql-default/App.jsonl.template +4 -4
- package/dist/templates/datasets/mysql-default/Company.jsonl.template +3 -3
- package/dist/templates/datasets/mysql-default/Person.jsonl.template +2 -2
- package/dist/templates/datasets/mysql-default/User.jsonl.template +1 -0
- package/dist/templates/datasets/mysql-default/instructions.md.template +1 -0
- package/dist/templates/datasets/postgres-default/.slingr-schema.json.template +5 -0
- package/dist/templates/datasets/postgres-default/Address.jsonl.template +3 -3
- package/dist/templates/datasets/postgres-default/App.jsonl.template +4 -4
- package/dist/templates/datasets/postgres-default/Company.jsonl.template +3 -3
- package/dist/templates/datasets/postgres-default/Person.jsonl.template +2 -2
- package/dist/templates/datasets/postgres-default/User.jsonl.template +1 -0
- package/dist/templates/datasets/postgres-default/instructions.md.template +1 -0
- package/dist/templates/docker-compose.prod-test.yml.template +32 -0
- package/dist/templates/docker-compose.yml.template +24 -0
- package/dist/templates/docs/app-description.md.template +33 -33
- package/dist/templates/firebase.json.template +68 -0
- package/dist/templates/frontend/.umirc.ts.template +23 -0
- package/dist/templates/frontend/package.json.template +45 -0
- package/dist/templates/frontend/public/config.json +6 -0
- package/dist/templates/frontend/public/logo.svg +6 -0
- package/dist/templates/frontend/src/app.tsx.template +44 -0
- package/dist/templates/frontend/src/global.less.template +117 -0
- package/dist/templates/frontend/src/layouts/MainLayout.tsx.template +75 -0
- package/dist/templates/frontend/src/types/graphql-augmentation.d.ts.template +44 -0
- package/dist/templates/frontend/src/views/customViews/user/UserCreateView.tsx.template +18 -0
- package/dist/templates/frontend/src/views/customViews/user/UserEditView.tsx.template +29 -0
- package/dist/templates/frontend/src/views/customViews/user/UserReadView.tsx.template +24 -0
- package/dist/templates/frontend/src/views/customViews/user/UserTableView.tsx.template +38 -0
- package/dist/templates/frontend/src/views/customViews/welcome.tsx.template +34 -0
- package/dist/templates/frontend/tsconfig.json.template +50 -0
- package/dist/templates/gql/codegen.yml.template +25 -25
- package/dist/templates/gql/index.ts.template +17 -24
- package/dist/templates/gql/operations.graphql.template +30 -30
- package/dist/templates/ops/README.md.template +1045 -0
- package/dist/templates/ops/cloudbuild.yaml.template +161 -0
- package/dist/templates/ops/scripts/_utils.js.template +217 -0
- package/dist/templates/ops/scripts/deploy.js.template +145 -0
- package/dist/templates/ops/scripts/setup-gcp.js.template +330 -0
- package/dist/templates/ops/scripts/setup-secrets.js.template +76 -0
- package/dist/templates/ops/scripts/test-prod-local.js.template +49 -0
- package/dist/templates/package.json.template +50 -38
- package/dist/templates/pnpm-workspace.yaml.template +3 -0
- package/dist/templates/prompt-analysis.md.template +110 -110
- package/dist/templates/prompt-script-generation.md.template +258 -258
- package/dist/templates/src/Address.ts.template +28 -31
- package/dist/templates/src/App.ts.template +17 -61
- package/dist/templates/src/Company.ts.template +41 -47
- package/dist/templates/src/Models.test.ts.template +654 -654
- package/dist/templates/src/Person.test.ts.template +289 -289
- package/dist/templates/src/Person.ts.template +90 -105
- package/dist/templates/src/actions/index.ts.template +11 -11
- package/dist/templates/src/auth/permissions.ts.template +34 -0
- package/dist/templates/src/data/App.ts.template +48 -0
- package/dist/templates/src/data/User.ts.template +35 -0
- package/dist/templates/src/types/gql.d.ts.template +17 -17
- package/dist/templates/vscode/extensions.json +4 -3
- package/dist/templates/vscode/settings.json +17 -11
- package/dist/templates/workspace-package.json.template +21 -0
- package/dist/utils/buildCache.d.ts +12 -0
- package/dist/utils/buildCache.d.ts.map +1 -0
- package/dist/utils/buildCache.js +102 -0
- package/dist/utils/buildCache.js.map +1 -0
- package/dist/utils/checkFramework.d.ts +27 -0
- package/dist/utils/checkFramework.d.ts.map +1 -0
- package/dist/utils/checkFramework.js +104 -0
- package/dist/utils/checkFramework.js.map +1 -0
- package/dist/utils/datasourceParser.d.ts +11 -0
- package/dist/utils/datasourceParser.d.ts.map +1 -1
- package/dist/utils/datasourceParser.js +154 -56
- package/dist/utils/datasourceParser.js.map +1 -1
- package/dist/utils/dockerManager.d.ts +25 -0
- package/dist/utils/dockerManager.d.ts.map +1 -0
- package/dist/utils/dockerManager.js +281 -0
- package/dist/utils/dockerManager.js.map +1 -0
- package/dist/utils/infraFileParser.d.ts +26 -0
- package/dist/utils/infraFileParser.d.ts.map +1 -0
- package/dist/utils/infraFileParser.js +75 -0
- package/dist/utils/infraFileParser.js.map +1 -0
- package/dist/utils/jsonlLoader.d.ts +91 -12
- package/dist/utils/jsonlLoader.d.ts.map +1 -1
- package/dist/utils/jsonlLoader.js +674 -63
- package/dist/utils/jsonlLoader.js.map +1 -1
- package/dist/utils/model-analyzer.d.ts.map +1 -1
- package/dist/utils/model-analyzer.js +67 -13
- package/dist/utils/model-analyzer.js.map +1 -1
- package/dist/utils/userManagement.d.ts +57 -0
- package/dist/utils/userManagement.d.ts.map +1 -0
- package/dist/utils/userManagement.js +288 -0
- package/dist/utils/userManagement.js.map +1 -0
- package/dist/utils/viewsGenerator.d.ts +15 -0
- package/dist/utils/viewsGenerator.d.ts.map +1 -0
- package/dist/utils/viewsGenerator.js +311 -0
- package/dist/utils/viewsGenerator.js.map +1 -0
- package/oclif.manifest.json +445 -20
- package/package.json +29 -26
- package/src/templates/.env.template +23 -0
- package/src/templates/.firebaserc.template +5 -0
- package/src/templates/.github/copilot-instructions.md.template +652 -17
- package/src/templates/backend/Dockerfile.template +30 -0
- package/src/templates/config/datasource.ts.template +12 -9
- package/src/templates/config/jest.config.ts +30 -30
- package/src/templates/config/jest.setup.ts +1 -1
- package/src/templates/config/tsconfig.json.template +50 -29
- package/src/templates/dataSources/mysql.ts.template +16 -13
- package/src/templates/dataSources/postgres.ts.template +15 -13
- package/src/templates/dataset-generator-script.ts.template +139 -139
- package/src/templates/datasets/mysql-default/.slingr-schema.json.template +5 -0
- package/src/templates/datasets/mysql-default/Address.jsonl.template +3 -3
- package/src/templates/datasets/mysql-default/App.jsonl.template +4 -4
- package/src/templates/datasets/mysql-default/Company.jsonl.template +3 -3
- package/src/templates/datasets/mysql-default/Person.jsonl.template +2 -2
- package/src/templates/datasets/mysql-default/User.jsonl.template +1 -0
- package/src/templates/datasets/mysql-default/instructions.md.template +1 -0
- package/src/templates/datasets/postgres-default/.slingr-schema.json.template +5 -0
- package/src/templates/datasets/postgres-default/Address.jsonl.template +3 -3
- package/src/templates/datasets/postgres-default/App.jsonl.template +4 -4
- package/src/templates/datasets/postgres-default/Company.jsonl.template +3 -3
- package/src/templates/datasets/postgres-default/Person.jsonl.template +2 -2
- package/src/templates/datasets/postgres-default/User.jsonl.template +1 -0
- package/src/templates/datasets/postgres-default/instructions.md.template +1 -0
- package/src/templates/docker-compose.prod-test.yml.template +32 -0
- package/src/templates/docker-compose.yml.template +24 -0
- package/src/templates/docs/app-description.md.template +33 -33
- package/src/templates/firebase.json.template +68 -0
- package/src/templates/frontend/.umirc.ts.template +23 -0
- package/src/templates/frontend/package.json.template +45 -0
- package/src/templates/frontend/public/config.json +6 -0
- package/src/templates/frontend/public/logo.svg +6 -0
- package/src/templates/frontend/src/app.tsx.template +44 -0
- package/src/templates/frontend/src/global.less.template +117 -0
- package/src/templates/frontend/src/layouts/MainLayout.tsx.template +75 -0
- package/src/templates/frontend/src/types/graphql-augmentation.d.ts.template +44 -0
- package/src/templates/frontend/src/views/customViews/user/UserCreateView.tsx.template +18 -0
- package/src/templates/frontend/src/views/customViews/user/UserEditView.tsx.template +29 -0
- package/src/templates/frontend/src/views/customViews/user/UserReadView.tsx.template +24 -0
- package/src/templates/frontend/src/views/customViews/user/UserTableView.tsx.template +38 -0
- package/src/templates/frontend/src/views/customViews/welcome.tsx.template +34 -0
- package/src/templates/frontend/tsconfig.json.template +50 -0
- package/src/templates/gql/codegen.yml.template +25 -25
- package/src/templates/gql/index.ts.template +17 -24
- package/src/templates/gql/operations.graphql.template +30 -30
- package/src/templates/ops/README.md.template +1045 -0
- package/src/templates/ops/cloudbuild.yaml.template +161 -0
- package/src/templates/ops/scripts/_utils.js.template +217 -0
- package/src/templates/ops/scripts/deploy.js.template +145 -0
- package/src/templates/ops/scripts/setup-gcp.js.template +330 -0
- package/src/templates/ops/scripts/setup-secrets.js.template +76 -0
- package/src/templates/ops/scripts/test-prod-local.js.template +49 -0
- package/src/templates/package.json.template +50 -38
- package/src/templates/pnpm-workspace.yaml.template +3 -0
- package/src/templates/prompt-analysis.md.template +110 -110
- package/src/templates/prompt-script-generation.md.template +258 -258
- package/src/templates/src/Address.ts.template +28 -31
- package/src/templates/src/App.ts.template +17 -61
- package/src/templates/src/Company.ts.template +41 -47
- package/src/templates/src/Models.test.ts.template +654 -654
- package/src/templates/src/Person.test.ts.template +289 -289
- package/src/templates/src/Person.ts.template +90 -105
- package/src/templates/src/actions/index.ts.template +11 -11
- package/src/templates/src/auth/permissions.ts.template +34 -0
- package/src/templates/src/data/App.ts.template +48 -0
- package/src/templates/src/data/User.ts.template +35 -0
- package/src/templates/src/types/gql.d.ts.template +17 -17
- package/src/templates/vscode/extensions.json +4 -3
- package/src/templates/vscode/settings.json +17 -11
- package/src/templates/workspace-package.json.template +21 -0
- package/dist/templates/src/index.ts +0 -66
- package/src/templates/src/index.ts +0 -66
package/oclif.manifest.json
CHANGED
|
@@ -1,5 +1,71 @@
|
|
|
1
1
|
{
|
|
2
2
|
"commands": {
|
|
3
|
+
"build": {
|
|
4
|
+
"aliases": [],
|
|
5
|
+
"args": {},
|
|
6
|
+
"description": "Build a Slingr application: sync metadata, compile backend TypeScript, and build frontend.\n\nUse this command instead of running `npm run build` directly. It ensures all generated files\n(view registries, GraphQL schema and SDK) are up-to-date before TypeScript compilation,\npreventing errors like \"Cannot find module '../src/views/...'\" in generated/ files.",
|
|
7
|
+
"examples": [
|
|
8
|
+
"<%= config.bin %> <%= command.id %>",
|
|
9
|
+
"<%= config.bin %> <%= command.id %> --skip-frontend",
|
|
10
|
+
"<%= config.bin %> <%= command.id %> --skip-metadata",
|
|
11
|
+
"<%= config.bin %> <%= command.id %> --verbose"
|
|
12
|
+
],
|
|
13
|
+
"flags": {
|
|
14
|
+
"help": {
|
|
15
|
+
"char": "h",
|
|
16
|
+
"description": "Show CLI help.",
|
|
17
|
+
"name": "help",
|
|
18
|
+
"allowNo": false,
|
|
19
|
+
"type": "boolean"
|
|
20
|
+
},
|
|
21
|
+
"skip-metadata": {
|
|
22
|
+
"char": "m",
|
|
23
|
+
"description": "Skip sync-metadata step (view registries, schema, SDK generation)",
|
|
24
|
+
"name": "skip-metadata",
|
|
25
|
+
"required": false,
|
|
26
|
+
"allowNo": false,
|
|
27
|
+
"type": "boolean"
|
|
28
|
+
},
|
|
29
|
+
"skip-backend": {
|
|
30
|
+
"char": "b",
|
|
31
|
+
"description": "Skip backend TypeScript compilation",
|
|
32
|
+
"name": "skip-backend",
|
|
33
|
+
"required": false,
|
|
34
|
+
"allowNo": false,
|
|
35
|
+
"type": "boolean"
|
|
36
|
+
},
|
|
37
|
+
"skip-frontend": {
|
|
38
|
+
"char": "f",
|
|
39
|
+
"description": "Skip frontend build",
|
|
40
|
+
"name": "skip-frontend",
|
|
41
|
+
"required": false,
|
|
42
|
+
"allowNo": false,
|
|
43
|
+
"type": "boolean"
|
|
44
|
+
},
|
|
45
|
+
"verbose": {
|
|
46
|
+
"char": "v",
|
|
47
|
+
"description": "Show detailed build and compilation output",
|
|
48
|
+
"name": "verbose",
|
|
49
|
+
"required": false,
|
|
50
|
+
"allowNo": false,
|
|
51
|
+
"type": "boolean"
|
|
52
|
+
}
|
|
53
|
+
},
|
|
54
|
+
"hasDynamicHelp": false,
|
|
55
|
+
"hiddenAliases": [],
|
|
56
|
+
"id": "build",
|
|
57
|
+
"pluginAlias": "@slingr/cli",
|
|
58
|
+
"pluginName": "@slingr/cli",
|
|
59
|
+
"pluginType": "core",
|
|
60
|
+
"strict": true,
|
|
61
|
+
"enableJsonFlag": false,
|
|
62
|
+
"isESM": false,
|
|
63
|
+
"relativePath": [
|
|
64
|
+
"dist",
|
|
65
|
+
"commands",
|
|
66
|
+
"build.js"
|
|
67
|
+
]
|
|
68
|
+
},
|
|
3
69
|
"cli-build": {
|
|
4
70
|
"aliases": [
|
|
5
71
|
"cli-build"
|
|
@@ -40,8 +106,8 @@
|
|
|
40
106
|
"<%= config.bin %> <%= command.id %>",
|
|
41
107
|
"<%= config.bin %> <%= command.id %> my-app",
|
|
42
108
|
"<%= config.bin %> <%= command.id %> task-manager",
|
|
43
|
-
"<%= config.bin %> <%= command.id %> my-crm --
|
|
44
|
-
"<%= config.bin %> <%= command.id %> my-crm --
|
|
109
|
+
"<%= config.bin %> <%= command.id %> my-crm --database=postgres --description=\"A CRM system for managing customers\"",
|
|
110
|
+
"<%= config.bin %> <%= command.id %> my-crm --database=postgres --description=\"A CRM system for managing customers\" -T"
|
|
45
111
|
],
|
|
46
112
|
"flags": {
|
|
47
113
|
"backend": {
|
|
@@ -99,19 +165,97 @@
|
|
|
99
165
|
"name": "templates",
|
|
100
166
|
"allowNo": false,
|
|
101
167
|
"type": "boolean"
|
|
168
|
+
}
|
|
169
|
+
},
|
|
170
|
+
"hasDynamicHelp": false,
|
|
171
|
+
"hiddenAliases": [],
|
|
172
|
+
"id": "create-app",
|
|
173
|
+
"pluginAlias": "@slingr/cli",
|
|
174
|
+
"pluginName": "@slingr/cli",
|
|
175
|
+
"pluginType": "core",
|
|
176
|
+
"strict": true,
|
|
177
|
+
"enableJsonFlag": false,
|
|
178
|
+
"isESM": false,
|
|
179
|
+
"relativePath": [
|
|
180
|
+
"dist",
|
|
181
|
+
"commands",
|
|
182
|
+
"create-app.js"
|
|
183
|
+
]
|
|
184
|
+
},
|
|
185
|
+
"debug": {
|
|
186
|
+
"aliases": [],
|
|
187
|
+
"args": {},
|
|
188
|
+
"description": "Run a Slingr application locally with Node.js debugging enabled.\n\nBehaves exactly like \"slingr run\" but starts the backend with the Node.js inspector. Use --dev for hot-reload development mode (ts-node + UI dev server, both with debugger).\nWithout --dev, runs in production mode (compiled backend, static UI, single port).",
|
|
189
|
+
"examples": [
|
|
190
|
+
"<%= config.bin %> <%= command.id %>",
|
|
191
|
+
"<%= config.bin %> <%= command.id %> --skip-infra",
|
|
192
|
+
"<%= config.bin %> <%= command.id %> --inspect-brk",
|
|
193
|
+
"<%= config.bin %> <%= command.id %> --inspect-port 9230",
|
|
194
|
+
"<%= config.bin %> <%= command.id %> --dev",
|
|
195
|
+
"<%= config.bin %> <%= command.id %> --dev --inspect-brk"
|
|
196
|
+
],
|
|
197
|
+
"flags": {
|
|
198
|
+
"help": {
|
|
199
|
+
"char": "h",
|
|
200
|
+
"description": "Show CLI help.",
|
|
201
|
+
"name": "help",
|
|
202
|
+
"allowNo": false,
|
|
203
|
+
"type": "boolean"
|
|
204
|
+
},
|
|
205
|
+
"dev": {
|
|
206
|
+
"char": "d",
|
|
207
|
+
"description": "Run in development mode with hot-reload (ts-node + UI dev server). The debugger is attached via NODE_OPTIONS.",
|
|
208
|
+
"name": "dev",
|
|
209
|
+
"required": false,
|
|
210
|
+
"allowNo": false,
|
|
211
|
+
"type": "boolean"
|
|
102
212
|
},
|
|
103
|
-
"
|
|
104
|
-
"char": "
|
|
105
|
-
"description": "
|
|
106
|
-
"name": "
|
|
213
|
+
"inspect-brk": {
|
|
214
|
+
"char": "b",
|
|
215
|
+
"description": "Break before user code starts (--inspect-brk)",
|
|
216
|
+
"name": "inspect-brk",
|
|
217
|
+
"required": false,
|
|
218
|
+
"allowNo": false,
|
|
219
|
+
"type": "boolean"
|
|
220
|
+
},
|
|
221
|
+
"inspect-port": {
|
|
222
|
+
"char": "p",
|
|
223
|
+
"description": "Port for Node.js debugger (default: 9229)",
|
|
224
|
+
"name": "inspect-port",
|
|
225
|
+
"required": false,
|
|
226
|
+
"default": 9229,
|
|
107
227
|
"hasDynamicHelp": false,
|
|
108
228
|
"multiple": false,
|
|
109
229
|
"type": "option"
|
|
230
|
+
},
|
|
231
|
+
"skip-infra": {
|
|
232
|
+
"char": "i",
|
|
233
|
+
"description": "Skip infrastructure setup and checks",
|
|
234
|
+
"name": "skip-infra",
|
|
235
|
+
"required": false,
|
|
236
|
+
"allowNo": false,
|
|
237
|
+
"type": "boolean"
|
|
238
|
+
},
|
|
239
|
+
"port": {
|
|
240
|
+
"description": "Custom port for the server (default: 3000)",
|
|
241
|
+
"name": "port",
|
|
242
|
+
"required": false,
|
|
243
|
+
"hasDynamicHelp": false,
|
|
244
|
+
"multiple": false,
|
|
245
|
+
"type": "option"
|
|
246
|
+
},
|
|
247
|
+
"verbose": {
|
|
248
|
+
"char": "v",
|
|
249
|
+
"description": "Show detailed build and setup output",
|
|
250
|
+
"name": "verbose",
|
|
251
|
+
"required": false,
|
|
252
|
+
"allowNo": false,
|
|
253
|
+
"type": "boolean"
|
|
110
254
|
}
|
|
111
255
|
},
|
|
112
256
|
"hasDynamicHelp": false,
|
|
113
257
|
"hiddenAliases": [],
|
|
114
|
-
"id": "
|
|
258
|
+
"id": "debug",
|
|
115
259
|
"pluginAlias": "@slingr/cli",
|
|
116
260
|
"pluginName": "@slingr/cli",
|
|
117
261
|
"pluginType": "core",
|
|
@@ -121,7 +265,7 @@
|
|
|
121
265
|
"relativePath": [
|
|
122
266
|
"dist",
|
|
123
267
|
"commands",
|
|
124
|
-
"
|
|
268
|
+
"debug.js"
|
|
125
269
|
]
|
|
126
270
|
},
|
|
127
271
|
"ds": {
|
|
@@ -133,11 +277,12 @@
|
|
|
133
277
|
"required": true
|
|
134
278
|
},
|
|
135
279
|
"action": {
|
|
136
|
-
"description": "Action to perform (load or
|
|
280
|
+
"description": "Action to perform (load, reset, or indexes)",
|
|
137
281
|
"name": "action",
|
|
138
282
|
"options": [
|
|
139
283
|
"load",
|
|
140
|
-
"reset"
|
|
284
|
+
"reset",
|
|
285
|
+
"indexes"
|
|
141
286
|
],
|
|
142
287
|
"required": true
|
|
143
288
|
},
|
|
@@ -148,14 +293,44 @@
|
|
|
148
293
|
"required": false
|
|
149
294
|
}
|
|
150
295
|
},
|
|
151
|
-
"description": "Manage datasets
|
|
296
|
+
"description": "Manage datasets and inspect datasources",
|
|
152
297
|
"examples": [
|
|
153
|
-
"
|
|
154
|
-
"
|
|
155
|
-
"
|
|
156
|
-
"
|
|
298
|
+
"<%= config.bin %> <%= command.id %> mainDs load",
|
|
299
|
+
"<%= config.bin %> <%= command.id %> postgres load custom-dataset",
|
|
300
|
+
"<%= config.bin %> <%= command.id %> mainDs load --includeModels=User,Project",
|
|
301
|
+
"<%= config.bin %> <%= command.id %> mainDs load --includeModels=\"User,Project\"",
|
|
302
|
+
"<%= config.bin %> <%= command.id %> mainDs load --excludeModels=TestData",
|
|
303
|
+
"<%= config.bin %> <%= command.id %> mainDs load --verbose",
|
|
304
|
+
"<%= config.bin %> <%= command.id %> postgres reset",
|
|
305
|
+
"<%= config.bin %> <%= command.id %> mainDs indexes",
|
|
306
|
+
"<%= config.bin %> <%= command.id %> mainDs indexes --verbose"
|
|
157
307
|
],
|
|
158
|
-
"flags": {
|
|
308
|
+
"flags": {
|
|
309
|
+
"includeModels": {
|
|
310
|
+
"description": "Comma-separated list of model names to load. Only these models will be loaded (overrides datasetOptions.json). Use --includeModels=Model1,Model2 or --includeModels \"Model1,Model2\" syntax.",
|
|
311
|
+
"name": "includeModels",
|
|
312
|
+
"required": false,
|
|
313
|
+
"hasDynamicHelp": false,
|
|
314
|
+
"multiple": false,
|
|
315
|
+
"type": "option"
|
|
316
|
+
},
|
|
317
|
+
"excludeModels": {
|
|
318
|
+
"description": "Comma-separated list of model names to skip. All other models will be loaded (overrides datasetOptions.json). Use --excludeModels=Model1,Model2 or --excludeModels \"Model1,Model2\" syntax.",
|
|
319
|
+
"name": "excludeModels",
|
|
320
|
+
"required": false,
|
|
321
|
+
"hasDynamicHelp": false,
|
|
322
|
+
"multiple": false,
|
|
323
|
+
"type": "option"
|
|
324
|
+
},
|
|
325
|
+
"verbose": {
|
|
326
|
+
"char": "v",
|
|
327
|
+
"description": "Show detailed logs during dataset loading. Without this flag, only success and validation error messages are displayed.",
|
|
328
|
+
"name": "verbose",
|
|
329
|
+
"required": false,
|
|
330
|
+
"allowNo": false,
|
|
331
|
+
"type": "boolean"
|
|
332
|
+
}
|
|
333
|
+
},
|
|
159
334
|
"hasDynamicHelp": false,
|
|
160
335
|
"hiddenAliases": [],
|
|
161
336
|
"id": "ds",
|
|
@@ -216,10 +391,13 @@
|
|
|
216
391
|
"run": {
|
|
217
392
|
"aliases": [],
|
|
218
393
|
"args": {},
|
|
219
|
-
"description": "Run a Slingr application locally",
|
|
394
|
+
"description": "Run a Slingr application locally with both backend and frontend on a single port.\n\nBy default, runs in production mode (unified server). Use --dev flag for hot-reload development with separate processes.",
|
|
220
395
|
"examples": [
|
|
221
396
|
"<%= config.bin %> <%= command.id %>",
|
|
222
|
-
"<%= config.bin %> <%= command.id %> --skip-infra"
|
|
397
|
+
"<%= config.bin %> <%= command.id %> --skip-infra",
|
|
398
|
+
"<%= config.bin %> <%= command.id %> --dev",
|
|
399
|
+
"<%= config.bin %> <%= command.id %> --ui-only",
|
|
400
|
+
"<%= config.bin %> <%= command.id %> --backend"
|
|
223
401
|
],
|
|
224
402
|
"flags": {
|
|
225
403
|
"help": {
|
|
@@ -231,11 +409,63 @@
|
|
|
231
409
|
},
|
|
232
410
|
"skip-infra": {
|
|
233
411
|
"char": "i",
|
|
234
|
-
"description": "Skip infrastructure setup and checks",
|
|
412
|
+
"description": "Skip infrastructure setup and checks (use when database containers are already running)",
|
|
235
413
|
"name": "skip-infra",
|
|
236
414
|
"required": false,
|
|
237
415
|
"allowNo": false,
|
|
238
416
|
"type": "boolean"
|
|
417
|
+
},
|
|
418
|
+
"dev": {
|
|
419
|
+
"char": "d",
|
|
420
|
+
"description": "Run in development mode with hot-reload (starts UI dev server and backend separately). Mutually exclusive with --ui-only and --backend.",
|
|
421
|
+
"exclusive": [
|
|
422
|
+
"ui-only",
|
|
423
|
+
"backend"
|
|
424
|
+
],
|
|
425
|
+
"name": "dev",
|
|
426
|
+
"required": false,
|
|
427
|
+
"allowNo": false,
|
|
428
|
+
"type": "boolean"
|
|
429
|
+
},
|
|
430
|
+
"ui-only": {
|
|
431
|
+
"description": "Start only the UI development server (backend must be running separately). Mutually exclusive with --dev and --backend.",
|
|
432
|
+
"exclusive": [
|
|
433
|
+
"dev",
|
|
434
|
+
"backend"
|
|
435
|
+
],
|
|
436
|
+
"name": "ui-only",
|
|
437
|
+
"required": false,
|
|
438
|
+
"allowNo": false,
|
|
439
|
+
"type": "boolean"
|
|
440
|
+
},
|
|
441
|
+
"backend": {
|
|
442
|
+
"char": "b",
|
|
443
|
+
"description": "Start only the backend server (use with --ui-only for split development). Mutually exclusive with --dev and --ui-only.",
|
|
444
|
+
"exclusive": [
|
|
445
|
+
"dev",
|
|
446
|
+
"ui-only"
|
|
447
|
+
],
|
|
448
|
+
"name": "backend",
|
|
449
|
+
"required": false,
|
|
450
|
+
"allowNo": false,
|
|
451
|
+
"type": "boolean"
|
|
452
|
+
},
|
|
453
|
+
"port": {
|
|
454
|
+
"char": "p",
|
|
455
|
+
"description": "Custom port for the server (default: 3000 or first available)",
|
|
456
|
+
"name": "port",
|
|
457
|
+
"required": false,
|
|
458
|
+
"hasDynamicHelp": false,
|
|
459
|
+
"multiple": false,
|
|
460
|
+
"type": "option"
|
|
461
|
+
},
|
|
462
|
+
"verbose": {
|
|
463
|
+
"char": "v",
|
|
464
|
+
"description": "Show detailed build and setup output and enable DEBUG level logs",
|
|
465
|
+
"name": "verbose",
|
|
466
|
+
"required": false,
|
|
467
|
+
"allowNo": false,
|
|
468
|
+
"type": "boolean"
|
|
239
469
|
}
|
|
240
470
|
},
|
|
241
471
|
"hasDynamicHelp": false,
|
|
@@ -304,6 +534,201 @@
|
|
|
304
534
|
"setup.js"
|
|
305
535
|
]
|
|
306
536
|
},
|
|
537
|
+
"sync-metadata": {
|
|
538
|
+
"aliases": [],
|
|
539
|
+
"args": {},
|
|
540
|
+
"description": "Sync all generated metadata files (view registries, GraphQL schema, and SDK)",
|
|
541
|
+
"examples": [
|
|
542
|
+
"<%= config.bin %> <%= command.id %>",
|
|
543
|
+
"<%= config.bin %> <%= command.id %> --skip-views",
|
|
544
|
+
"<%= config.bin %> <%= command.id %> --skip-sdk"
|
|
545
|
+
],
|
|
546
|
+
"flags": {
|
|
547
|
+
"skip-views": {
|
|
548
|
+
"description": "Skip view registry generation",
|
|
549
|
+
"name": "skip-views",
|
|
550
|
+
"allowNo": false,
|
|
551
|
+
"type": "boolean"
|
|
552
|
+
},
|
|
553
|
+
"skip-schema": {
|
|
554
|
+
"description": "Skip GraphQL schema generation",
|
|
555
|
+
"name": "skip-schema",
|
|
556
|
+
"allowNo": false,
|
|
557
|
+
"type": "boolean"
|
|
558
|
+
},
|
|
559
|
+
"skip-sdk": {
|
|
560
|
+
"description": "Skip GraphQL SDK generation",
|
|
561
|
+
"name": "skip-sdk",
|
|
562
|
+
"allowNo": false,
|
|
563
|
+
"type": "boolean"
|
|
564
|
+
}
|
|
565
|
+
},
|
|
566
|
+
"hasDynamicHelp": false,
|
|
567
|
+
"hiddenAliases": [],
|
|
568
|
+
"id": "sync-metadata",
|
|
569
|
+
"pluginAlias": "@slingr/cli",
|
|
570
|
+
"pluginName": "@slingr/cli",
|
|
571
|
+
"pluginType": "core",
|
|
572
|
+
"strict": true,
|
|
573
|
+
"enableJsonFlag": false,
|
|
574
|
+
"isESM": false,
|
|
575
|
+
"relativePath": [
|
|
576
|
+
"dist",
|
|
577
|
+
"commands",
|
|
578
|
+
"sync-metadata.js"
|
|
579
|
+
]
|
|
580
|
+
},
|
|
581
|
+
"users": {
|
|
582
|
+
"aliases": [],
|
|
583
|
+
"args": {
|
|
584
|
+
"action": {
|
|
585
|
+
"description": "Action to perform",
|
|
586
|
+
"name": "action",
|
|
587
|
+
"options": [
|
|
588
|
+
"list",
|
|
589
|
+
"create",
|
|
590
|
+
"set-password",
|
|
591
|
+
"reset-password",
|
|
592
|
+
"activate",
|
|
593
|
+
"deactivate",
|
|
594
|
+
"delete"
|
|
595
|
+
],
|
|
596
|
+
"required": true
|
|
597
|
+
},
|
|
598
|
+
"email": {
|
|
599
|
+
"description": "User email (required for set-password, reset-password, activate, deactivate, delete)",
|
|
600
|
+
"name": "email",
|
|
601
|
+
"required": false
|
|
602
|
+
}
|
|
603
|
+
},
|
|
604
|
+
"description": "Manage application users",
|
|
605
|
+
"examples": [
|
|
606
|
+
"<%= config.bin %> <%= command.id %> list",
|
|
607
|
+
"<%= config.bin %> <%= command.id %> create",
|
|
608
|
+
"<%= config.bin %> <%= command.id %> create --email john@example.com --first-name John --last-name Doe --password pass123 --roles \"Admin,User\"",
|
|
609
|
+
"<%= config.bin %> <%= command.id %> set-password john@example.com",
|
|
610
|
+
"<%= config.bin %> <%= command.id %> set-password john@example.com --new-password newpass123",
|
|
611
|
+
"<%= config.bin %> <%= command.id %> reset-password john@example.com",
|
|
612
|
+
"<%= config.bin %> <%= command.id %> activate john@example.com",
|
|
613
|
+
"<%= config.bin %> <%= command.id %> deactivate john@example.com",
|
|
614
|
+
"<%= config.bin %> <%= command.id %> delete john@example.com --force"
|
|
615
|
+
],
|
|
616
|
+
"flags": {
|
|
617
|
+
"help": {
|
|
618
|
+
"char": "h",
|
|
619
|
+
"description": "Show CLI help.",
|
|
620
|
+
"name": "help",
|
|
621
|
+
"allowNo": false,
|
|
622
|
+
"type": "boolean"
|
|
623
|
+
},
|
|
624
|
+
"first-name": {
|
|
625
|
+
"description": "User first name",
|
|
626
|
+
"name": "first-name",
|
|
627
|
+
"hasDynamicHelp": false,
|
|
628
|
+
"multiple": false,
|
|
629
|
+
"type": "option"
|
|
630
|
+
},
|
|
631
|
+
"last-name": {
|
|
632
|
+
"description": "User last name",
|
|
633
|
+
"name": "last-name",
|
|
634
|
+
"hasDynamicHelp": false,
|
|
635
|
+
"multiple": false,
|
|
636
|
+
"type": "option"
|
|
637
|
+
},
|
|
638
|
+
"email": {
|
|
639
|
+
"char": "e",
|
|
640
|
+
"description": "User email address",
|
|
641
|
+
"name": "email",
|
|
642
|
+
"hasDynamicHelp": false,
|
|
643
|
+
"multiple": false,
|
|
644
|
+
"type": "option"
|
|
645
|
+
},
|
|
646
|
+
"password": {
|
|
647
|
+
"char": "p",
|
|
648
|
+
"description": "User password",
|
|
649
|
+
"name": "password",
|
|
650
|
+
"hasDynamicHelp": false,
|
|
651
|
+
"multiple": false,
|
|
652
|
+
"type": "option"
|
|
653
|
+
},
|
|
654
|
+
"roles": {
|
|
655
|
+
"char": "r",
|
|
656
|
+
"description": "Comma-separated list of roles",
|
|
657
|
+
"name": "roles",
|
|
658
|
+
"hasDynamicHelp": false,
|
|
659
|
+
"multiple": false,
|
|
660
|
+
"type": "option"
|
|
661
|
+
},
|
|
662
|
+
"new-password": {
|
|
663
|
+
"description": "New password for the user",
|
|
664
|
+
"name": "new-password",
|
|
665
|
+
"hasDynamicHelp": false,
|
|
666
|
+
"multiple": false,
|
|
667
|
+
"type": "option"
|
|
668
|
+
},
|
|
669
|
+
"force": {
|
|
670
|
+
"char": "f",
|
|
671
|
+
"description": "Skip confirmation prompts for destructive operations",
|
|
672
|
+
"name": "force",
|
|
673
|
+
"allowNo": false,
|
|
674
|
+
"type": "boolean"
|
|
675
|
+
},
|
|
676
|
+
"datasource": {
|
|
677
|
+
"char": "d",
|
|
678
|
+
"description": "DataSource name (auto-discovered from User model if not specified)",
|
|
679
|
+
"name": "datasource",
|
|
680
|
+
"hasDynamicHelp": false,
|
|
681
|
+
"multiple": false,
|
|
682
|
+
"type": "option"
|
|
683
|
+
}
|
|
684
|
+
},
|
|
685
|
+
"hasDynamicHelp": false,
|
|
686
|
+
"hiddenAliases": [],
|
|
687
|
+
"id": "users",
|
|
688
|
+
"pluginAlias": "@slingr/cli",
|
|
689
|
+
"pluginName": "@slingr/cli",
|
|
690
|
+
"pluginType": "core",
|
|
691
|
+
"strict": true,
|
|
692
|
+
"enableJsonFlag": false,
|
|
693
|
+
"isESM": false,
|
|
694
|
+
"relativePath": [
|
|
695
|
+
"dist",
|
|
696
|
+
"commands",
|
|
697
|
+
"users.js"
|
|
698
|
+
]
|
|
699
|
+
},
|
|
700
|
+
"views": {
|
|
701
|
+
"aliases": [],
|
|
702
|
+
"args": {
|
|
703
|
+
"action": {
|
|
704
|
+
"description": "Action to perform (generate-context)",
|
|
705
|
+
"name": "action",
|
|
706
|
+
"options": [
|
|
707
|
+
"generate-context"
|
|
708
|
+
],
|
|
709
|
+
"required": true
|
|
710
|
+
}
|
|
711
|
+
},
|
|
712
|
+
"description": "Manage custom views for your Slingr application",
|
|
713
|
+
"examples": [
|
|
714
|
+
"<%= config.bin %> <%= command.id %> generate-context"
|
|
715
|
+
],
|
|
716
|
+
"flags": {},
|
|
717
|
+
"hasDynamicHelp": false,
|
|
718
|
+
"hiddenAliases": [],
|
|
719
|
+
"id": "views",
|
|
720
|
+
"pluginAlias": "@slingr/cli",
|
|
721
|
+
"pluginName": "@slingr/cli",
|
|
722
|
+
"pluginType": "core",
|
|
723
|
+
"strict": true,
|
|
724
|
+
"enableJsonFlag": false,
|
|
725
|
+
"isESM": false,
|
|
726
|
+
"relativePath": [
|
|
727
|
+
"dist",
|
|
728
|
+
"commands",
|
|
729
|
+
"views.js"
|
|
730
|
+
]
|
|
731
|
+
},
|
|
307
732
|
"infra:down": {
|
|
308
733
|
"aliases": [],
|
|
309
734
|
"args": {},
|
|
@@ -431,5 +856,5 @@
|
|
|
431
856
|
]
|
|
432
857
|
}
|
|
433
858
|
},
|
|
434
|
-
"version": "0.0.
|
|
859
|
+
"version": "0.0.4"
|
|
435
860
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@slingr/cli",
|
|
3
3
|
"description": "Slingr CLI tool for creating and managing Slingr applications",
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.4",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
@@ -12,43 +12,47 @@
|
|
|
12
12
|
"@faker-js/faker": "^8.4.1",
|
|
13
13
|
"@oclif/core": "^4",
|
|
14
14
|
"@oclif/plugin-help": "^6",
|
|
15
|
+
"@types/cli-progress": "^3.11.6",
|
|
15
16
|
"@types/fs-extra": "^11.0.4",
|
|
16
17
|
"@types/inquirer": "^8.2.12",
|
|
17
18
|
"@types/js-yaml": "^4.0.9",
|
|
19
|
+
"cli-progress": "^3.12.0",
|
|
18
20
|
"fs-extra": "^11.3.1",
|
|
19
|
-
"glob": "^11.0.
|
|
21
|
+
"glob": "^11.0.3",
|
|
20
22
|
"graphql": "^16.11.0",
|
|
21
23
|
"inquirer": "^8.2.7",
|
|
22
24
|
"js-yaml": "^4.1.0",
|
|
23
25
|
"mocha": "^11.7.4",
|
|
24
|
-
"reflect-metadata": "^0.2.2"
|
|
26
|
+
"reflect-metadata": "^0.2.2",
|
|
27
|
+
"@slingr/framework-backend": "0.2.1"
|
|
25
28
|
},
|
|
26
29
|
"devDependencies": {
|
|
27
30
|
"@eslint/compat": "^1",
|
|
28
31
|
"@oclif/prettier-config": "^0.2.1",
|
|
29
32
|
"@oclif/test": "^4",
|
|
30
33
|
"@types/chai": "^4",
|
|
34
|
+
"@types/cli-progress": "^3.11.6",
|
|
31
35
|
"@types/mocha": "^10.0.6",
|
|
32
|
-
"@types/node": "^
|
|
36
|
+
"@types/node": "^20",
|
|
37
|
+
"c8": "^10.1.3",
|
|
33
38
|
"chai": "^4",
|
|
39
|
+
"cli-progress": "^3.12.0",
|
|
34
40
|
"eslint": "^9",
|
|
35
41
|
"eslint-config-oclif": "^6",
|
|
36
42
|
"eslint-config-prettier": "^10",
|
|
37
|
-
"nyc": "^17.1.0",
|
|
38
43
|
"oclif": "^4",
|
|
39
44
|
"shx": "^0.3.3",
|
|
40
45
|
"ts-node": "^10.9.2",
|
|
41
|
-
"
|
|
46
|
+
"tsx": "^4.21.0",
|
|
47
|
+
"typescript": "^5.9.2"
|
|
42
48
|
},
|
|
43
49
|
"overrides": {
|
|
44
|
-
"glob": "^11.0.
|
|
45
|
-
"inflight": "npm:@lukekarrys/inflight@^1.0.6"
|
|
46
|
-
"nyc": {
|
|
47
|
-
"rimraf": "^5.0.0"
|
|
48
|
-
}
|
|
50
|
+
"glob": "^11.0.3",
|
|
51
|
+
"inflight": "npm:@lukekarrys/inflight@^1.0.6"
|
|
49
52
|
},
|
|
50
53
|
"engines": {
|
|
51
|
-
"node": ">=
|
|
54
|
+
"node": ">=20.0.0",
|
|
55
|
+
"npm": ">=10.0.0"
|
|
52
56
|
},
|
|
53
57
|
"files": [
|
|
54
58
|
"./bin",
|
|
@@ -83,18 +87,8 @@
|
|
|
83
87
|
],
|
|
84
88
|
"topicSeparator": " "
|
|
85
89
|
},
|
|
86
|
-
"scripts": {
|
|
87
|
-
"build": "shx rm -rf dist && tsc -b && shx cp -r src/templates dist/ && shx cp -r src/scripts dist/",
|
|
88
|
-
"lint": "eslint",
|
|
89
|
-
"postpack": "shx rm -f oclif.manifest.json",
|
|
90
|
-
"prepack": "npm run build && oclif manifest && oclif readme",
|
|
91
|
-
"setup": "npm run build && npm run prepack && npm link",
|
|
92
|
-
"test": "mocha -r ts-node/register --timeout 60000 --forbid-only \"test/**/*.test.ts\"",
|
|
93
|
-
"coverage": "nyc --reporter=text --reporter=text-summary --reporter=json-summary mocha --forbid-only \"test/**/*.test.ts\"",
|
|
94
|
-
"version": "oclif readme && git add README.md"
|
|
95
|
-
},
|
|
96
90
|
"types": "dist/index.d.ts",
|
|
97
|
-
"
|
|
91
|
+
"c8": {
|
|
98
92
|
"include": [
|
|
99
93
|
"src/**/*.ts"
|
|
100
94
|
],
|
|
@@ -110,8 +104,17 @@
|
|
|
110
104
|
"json-summary"
|
|
111
105
|
],
|
|
112
106
|
"sourceMap": true,
|
|
113
|
-
"
|
|
114
|
-
|
|
115
|
-
|
|
107
|
+
"all": true
|
|
108
|
+
},
|
|
109
|
+
"scripts": {
|
|
110
|
+
"build": "shx rm -rf dist lib/node_modules && tsc -b && shx cp -r src/templates dist/ && shx cp -r src/scripts dist/",
|
|
111
|
+
"lint": "eslint",
|
|
112
|
+
"setup": "npm run build && npm run prepack && npm link",
|
|
113
|
+
"test": "node scripts/run-mocha.js -r ts-node/register --timeout 60000 --forbid-only --default-spec test/**/*.test.ts --",
|
|
114
|
+
"test:unit": "node scripts/run-mocha.js -r ts-node/register --timeout 30000 --forbid-only --default-spec test/*.test.ts --default-spec test/commands/**/*.test.ts --",
|
|
115
|
+
"test:integration": "node scripts/run-mocha.js -r ts-node/register --timeout 120000 --forbid-only --default-spec test/integration/**/*.test.ts --",
|
|
116
|
+
"coverage": "c8 --reporter=text --reporter=text-summary --reporter=json-summary node scripts/run-mocha.js -r ts-node/register --timeout 60000 --forbid-only --default-spec test/**/*.test.ts --",
|
|
117
|
+
"coverage:integration": "c8 --reporter=text --reporter=text-summary --reporter=json-summary node scripts/run-mocha.js -r ts-node/register --timeout 120000 --forbid-only --default-spec test/integration/**/*.test.ts --",
|
|
118
|
+
"version": "oclif readme && git add README.md"
|
|
116
119
|
}
|
|
117
120
|
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Slingr Application Configuration
|
|
2
|
+
# This file contains environment-specific configuration for your Slingr app.
|
|
3
|
+
# Copy this file to .env and customize the values as needed.
|
|
4
|
+
|
|
5
|
+
# GraphQL Server Configuration
|
|
6
|
+
GRAPHQL_HOST=localhost
|
|
7
|
+
GRAPHQL_PORT=3000
|
|
8
|
+
GRAPHQL_ENABLE_EXPLORER=true
|
|
9
|
+
|
|
10
|
+
# Note: These values can be overridden by:
|
|
11
|
+
# 1. app.configure() method in your code
|
|
12
|
+
# 2. app.run() options parameter
|
|
13
|
+
# Configuration priority: .env < configure() < run(options)
|
|
14
|
+
|
|
15
|
+
# JWT Configuration
|
|
16
|
+
JWT_SECRET=your-secret-key-change-in-production
|
|
17
|
+
|
|
18
|
+
# Database Configuration
|
|
19
|
+
DB_HOST=localhost
|
|
20
|
+
DB_PORT=5432
|
|
21
|
+
DB_USER=postgres
|
|
22
|
+
DB_PASSWORD=postgres
|
|
23
|
+
DB_NAME={{APP_NAME}}
|