@foal/cli 3.0.0-alpha.1 → 3.0.1
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/lib/generate/templates/app/package.json +2 -2
- package/lib/generate/templates/app/package.mongodb.json +1 -1
- package/lib/generate/templates/app/package.mongodb.yaml.json +1 -1
- package/lib/generate/templates/app/package.yaml.json +2 -2
- package/lib/run-script/run-script.js +2 -0
- package/package.json +3 -2
|
@@ -24,8 +24,8 @@
|
|
|
24
24
|
"node": ">=16.0.0"
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@foal/core": "3.0.0
|
|
28
|
-
"@foal/typeorm": "3.0.0
|
|
27
|
+
"@foal/core": "^3.0.0",
|
|
28
|
+
"@foal/typeorm": "^3.0.0",
|
|
29
29
|
"source-map-support": "~0.5.21",
|
|
30
30
|
"better-sqlite3": "~7.6.2",
|
|
31
31
|
"typeorm": "0.3.10"
|
|
@@ -24,8 +24,8 @@
|
|
|
24
24
|
"node": ">=16.0.0"
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@foal/core": "3.0.0
|
|
28
|
-
"@foal/typeorm": "3.0.0
|
|
27
|
+
"@foal/core": "^3.0.0",
|
|
28
|
+
"@foal/typeorm": "^3.0.0",
|
|
29
29
|
"source-map-support": "~0.5.21",
|
|
30
30
|
"better-sqlite3": "~7.5.0",
|
|
31
31
|
"typeorm": "0.3.10",
|
|
@@ -6,6 +6,7 @@ const fs_1 = require("fs");
|
|
|
6
6
|
const path_1 = require("path");
|
|
7
7
|
// 3p
|
|
8
8
|
const ajv_1 = require("ajv");
|
|
9
|
+
const ajv_formats_1 = require("ajv-formats");
|
|
9
10
|
// FoalTS
|
|
10
11
|
const get_command_line_arguments_util_1 = require("./get-command-line-arguments.util");
|
|
11
12
|
async function runScript({ name }, argv, log = console.log) {
|
|
@@ -27,6 +28,7 @@ async function runScript({ name }, argv, log = console.log) {
|
|
|
27
28
|
const args = (0, get_command_line_arguments_util_1.getCommandLineArguments)(argv);
|
|
28
29
|
if (schema) {
|
|
29
30
|
const ajv = new ajv_1.default({ useDefaults: true });
|
|
31
|
+
(0, ajv_formats_1.default)(ajv);
|
|
30
32
|
if (!ajv.validate(schema, args)) {
|
|
31
33
|
ajv.errors.forEach(err => {
|
|
32
34
|
log(`Error: The command line arguments ${err.message}.`);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@foal/cli",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.1",
|
|
4
4
|
"description": "CLI tool for FoalTS",
|
|
5
5
|
"main": "./lib/index.js",
|
|
6
6
|
"types": "./lib/index.d.ts",
|
|
@@ -58,6 +58,7 @@
|
|
|
58
58
|
],
|
|
59
59
|
"dependencies": {
|
|
60
60
|
"ajv": "~8.11.0",
|
|
61
|
+
"ajv-formats": "~2.1.1",
|
|
61
62
|
"cli-spinner": "~0.2.10",
|
|
62
63
|
"colors": "1.4.0",
|
|
63
64
|
"commander": "~9.3.0"
|
|
@@ -71,5 +72,5 @@
|
|
|
71
72
|
"ts-node": "~10.8.1",
|
|
72
73
|
"typescript": "~4.7.4"
|
|
73
74
|
},
|
|
74
|
-
"gitHead": "
|
|
75
|
+
"gitHead": "9eb5a1542b8f98925e13de93773503fb79fae1fe"
|
|
75
76
|
}
|