@devkong/cli 0.0.7 → 0.0.10
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/assets/python-install.sh +1 -1
- package/index.js +86 -16
- package/package.json +1 -1
- package/assets/kong-json-schema.json +0 -136
package/assets/python-install.sh
CHANGED
package/index.js
CHANGED
|
@@ -42671,7 +42671,7 @@ var require_package2 = __commonJS({
|
|
|
42671
42671
|
"node_modules/create-nx-workspace/package.json"(exports2, module2) {
|
|
42672
42672
|
module2.exports = {
|
|
42673
42673
|
name: "create-nx-workspace",
|
|
42674
|
-
version: "20.1
|
|
42674
|
+
version: "20.2.1",
|
|
42675
42675
|
private: false,
|
|
42676
42676
|
description: "Smart Monorepos \xB7 Fast CI",
|
|
42677
42677
|
repository: {
|
|
@@ -43322,13 +43322,15 @@ var require_create_workspace = __commonJS({
|
|
|
43322
43322
|
var git_1 = require_git();
|
|
43323
43323
|
var get_third_party_preset_1 = require_get_third_party_preset();
|
|
43324
43324
|
var error_utils_1 = require_error_utils();
|
|
43325
|
+
var preset_1 = require_preset();
|
|
43325
43326
|
async function createWorkspace2(preset, options) {
|
|
43326
43327
|
const { packageManager, name, nxCloud, skipGit = false, defaultBase = "main", commit, cliName, useGitHub } = options;
|
|
43327
43328
|
if (cliName) {
|
|
43328
43329
|
output_1.output.setCliName(cliName ?? "NX");
|
|
43329
43330
|
}
|
|
43330
43331
|
const tmpDir = await (0, create_sandbox_1.createSandbox)(packageManager);
|
|
43331
|
-
const
|
|
43332
|
+
const workspaceGlobs = getWorkspaceGlobsFromPreset(preset);
|
|
43333
|
+
const directory = await (0, create_empty_workspace_1.createEmptyWorkspace)(tmpDir, name, packageManager, { ...options, preset, workspaceGlobs });
|
|
43332
43334
|
const thirdPartyPackageName = (0, get_third_party_preset_1.getPackageNameFromThirdPartyPreset)(preset);
|
|
43333
43335
|
if (thirdPartyPackageName) {
|
|
43334
43336
|
await (0, create_preset_1.createPreset)(thirdPartyPackageName, options, packageManager, directory);
|
|
@@ -43368,6 +43370,25 @@ var require_create_workspace = __commonJS({
|
|
|
43368
43370
|
const match2 = text.match(urlPattern);
|
|
43369
43371
|
return match2 ? match2[0] : null;
|
|
43370
43372
|
}
|
|
43373
|
+
function getWorkspaceGlobsFromPreset(preset) {
|
|
43374
|
+
switch (preset) {
|
|
43375
|
+
case preset_1.Preset.AngularMonorepo:
|
|
43376
|
+
case preset_1.Preset.Expo:
|
|
43377
|
+
case preset_1.Preset.Express:
|
|
43378
|
+
case preset_1.Preset.Nest:
|
|
43379
|
+
case preset_1.Preset.NextJs:
|
|
43380
|
+
case preset_1.Preset.NodeMonorepo:
|
|
43381
|
+
case preset_1.Preset.Nuxt:
|
|
43382
|
+
case preset_1.Preset.ReactNative:
|
|
43383
|
+
case preset_1.Preset.ReactMonorepo:
|
|
43384
|
+
case preset_1.Preset.RemixMonorepo:
|
|
43385
|
+
case preset_1.Preset.VueMonorepo:
|
|
43386
|
+
case preset_1.Preset.WebComponents:
|
|
43387
|
+
return ["apps/**", "packages/**"];
|
|
43388
|
+
default:
|
|
43389
|
+
return ["packages/**"];
|
|
43390
|
+
}
|
|
43391
|
+
}
|
|
43371
43392
|
}
|
|
43372
43393
|
});
|
|
43373
43394
|
|
|
@@ -47268,7 +47289,24 @@ var PromisePolyfill = class extends Promise {
|
|
|
47268
47289
|
};
|
|
47269
47290
|
|
|
47270
47291
|
// node_modules/@inquirer/core/dist/esm/lib/create-prompt.js
|
|
47292
|
+
function getCallSites() {
|
|
47293
|
+
const _prepareStackTrace = Error.prepareStackTrace;
|
|
47294
|
+
try {
|
|
47295
|
+
let result = [];
|
|
47296
|
+
Error.prepareStackTrace = (_2, callSites) => {
|
|
47297
|
+
const callSitesWithoutCurrent = callSites.slice(1);
|
|
47298
|
+
result = callSitesWithoutCurrent;
|
|
47299
|
+
return callSitesWithoutCurrent;
|
|
47300
|
+
};
|
|
47301
|
+
new Error().stack;
|
|
47302
|
+
return result;
|
|
47303
|
+
} finally {
|
|
47304
|
+
Error.prepareStackTrace = _prepareStackTrace;
|
|
47305
|
+
}
|
|
47306
|
+
}
|
|
47271
47307
|
function createPrompt(view) {
|
|
47308
|
+
const callSites = getCallSites();
|
|
47309
|
+
const callerFilename = callSites[1]?.getFileName?.();
|
|
47272
47310
|
const prompt2 = (config, context = {}) => {
|
|
47273
47311
|
const { input = process.stdin, signal } = context;
|
|
47274
47312
|
const cleanups = /* @__PURE__ */ new Set();
|
|
@@ -47306,6 +47344,10 @@ function createPrompt(view) {
|
|
|
47306
47344
|
const nextView = view(config, (value) => {
|
|
47307
47345
|
setImmediate(() => resolve2(value));
|
|
47308
47346
|
});
|
|
47347
|
+
if (nextView === void 0) {
|
|
47348
|
+
throw new Error(`Prompt functions must return a string.
|
|
47349
|
+
at ${callerFilename}`);
|
|
47350
|
+
}
|
|
47309
47351
|
const [content, bottomContent] = typeof nextView === "string" ? [nextView] : nextView;
|
|
47310
47352
|
screen.render(content, bottomContent);
|
|
47311
47353
|
effectScheduler.run();
|
|
@@ -47519,11 +47561,14 @@ ${page}${helpTipBottom}${choiceDescription}${error}${import_ansi_escapes2.defaul
|
|
|
47519
47561
|
// node_modules/@inquirer/editor/dist/esm/index.js
|
|
47520
47562
|
var import_node_async_hooks4 = require("node:async_hooks");
|
|
47521
47563
|
var import_external_editor = __toESM(require_main3(), 1);
|
|
47564
|
+
var editorTheme = {
|
|
47565
|
+
validationFailureMode: "keep"
|
|
47566
|
+
};
|
|
47522
47567
|
var esm_default3 = createPrompt((config, done) => {
|
|
47523
47568
|
const { waitForUseInput = true, file: { postfix = config.postfix ?? ".txt", ...fileProps } = {}, validate: validate4 = () => true } = config;
|
|
47524
|
-
const theme = makeTheme(config.theme);
|
|
47569
|
+
const theme = makeTheme(editorTheme, config.theme);
|
|
47525
47570
|
const [status, setStatus] = useState("idle");
|
|
47526
|
-
const [value, setValue] = useState(config.default
|
|
47571
|
+
const [value = "", setValue] = useState(config.default);
|
|
47527
47572
|
const [errorMsg, setError] = useState();
|
|
47528
47573
|
const prefix = usePrefix({ status, theme });
|
|
47529
47574
|
function startEditor(rl) {
|
|
@@ -47540,7 +47585,11 @@ var esm_default3 = createPrompt((config, done) => {
|
|
|
47540
47585
|
setStatus("done");
|
|
47541
47586
|
done(answer);
|
|
47542
47587
|
} else {
|
|
47543
|
-
|
|
47588
|
+
if (theme.validationFailureMode === "clear") {
|
|
47589
|
+
setValue(config.default);
|
|
47590
|
+
} else {
|
|
47591
|
+
setValue(answer);
|
|
47592
|
+
}
|
|
47544
47593
|
setError(isValid2 || "You must provide a valid value");
|
|
47545
47594
|
setStatus("idle");
|
|
47546
47595
|
}
|
|
@@ -47580,22 +47629,34 @@ var esm_default3 = createPrompt((config, done) => {
|
|
|
47580
47629
|
});
|
|
47581
47630
|
|
|
47582
47631
|
// node_modules/@inquirer/confirm/dist/esm/index.js
|
|
47632
|
+
function getBooleanValue(value, defaultValue) {
|
|
47633
|
+
let answer = defaultValue !== false;
|
|
47634
|
+
if (/^(y|yes)/i.test(value))
|
|
47635
|
+
answer = true;
|
|
47636
|
+
else if (/^(n|no)/i.test(value))
|
|
47637
|
+
answer = false;
|
|
47638
|
+
return answer;
|
|
47639
|
+
}
|
|
47640
|
+
function boolToString(value) {
|
|
47641
|
+
return value ? "Yes" : "No";
|
|
47642
|
+
}
|
|
47583
47643
|
var esm_default4 = createPrompt((config, done) => {
|
|
47584
|
-
const { transformer =
|
|
47644
|
+
const { transformer = boolToString } = config;
|
|
47585
47645
|
const [status, setStatus] = useState("idle");
|
|
47586
47646
|
const [value, setValue] = useState("");
|
|
47587
47647
|
const theme = makeTheme(config.theme);
|
|
47588
47648
|
const prefix = usePrefix({ status, theme });
|
|
47589
47649
|
useKeypress((key, rl) => {
|
|
47590
47650
|
if (isEnterKey(key)) {
|
|
47591
|
-
|
|
47592
|
-
if (/^(y|yes)/i.test(value))
|
|
47593
|
-
answer = true;
|
|
47594
|
-
else if (/^(n|no)/i.test(value))
|
|
47595
|
-
answer = false;
|
|
47651
|
+
const answer = getBooleanValue(value, config.default);
|
|
47596
47652
|
setValue(transformer(answer));
|
|
47597
47653
|
setStatus("done");
|
|
47598
47654
|
done(answer);
|
|
47655
|
+
} else if (key.name === "tab") {
|
|
47656
|
+
const answer = boolToString(!getBooleanValue(value, config.default));
|
|
47657
|
+
rl.clearLine(0);
|
|
47658
|
+
rl.write(answer);
|
|
47659
|
+
setValue(answer);
|
|
47599
47660
|
} else {
|
|
47600
47661
|
setValue(rl.line);
|
|
47601
47662
|
}
|
|
@@ -47612,9 +47673,12 @@ var esm_default4 = createPrompt((config, done) => {
|
|
|
47612
47673
|
});
|
|
47613
47674
|
|
|
47614
47675
|
// node_modules/@inquirer/input/dist/esm/index.js
|
|
47676
|
+
var inputTheme = {
|
|
47677
|
+
validationFailureMode: "keep"
|
|
47678
|
+
};
|
|
47615
47679
|
var esm_default5 = createPrompt((config, done) => {
|
|
47616
47680
|
const { required, validate: validate4 = () => true } = config;
|
|
47617
|
-
const theme = makeTheme(config.theme);
|
|
47681
|
+
const theme = makeTheme(inputTheme, config.theme);
|
|
47618
47682
|
const [status, setStatus] = useState("idle");
|
|
47619
47683
|
const [defaultValue = "", setDefaultValue] = useState(config.default);
|
|
47620
47684
|
const [errorMsg, setError] = useState();
|
|
@@ -47633,7 +47697,11 @@ var esm_default5 = createPrompt((config, done) => {
|
|
|
47633
47697
|
setStatus("done");
|
|
47634
47698
|
done(answer);
|
|
47635
47699
|
} else {
|
|
47636
|
-
|
|
47700
|
+
if (theme.validationFailureMode === "clear") {
|
|
47701
|
+
setValue("");
|
|
47702
|
+
} else {
|
|
47703
|
+
rl.write(value);
|
|
47704
|
+
}
|
|
47637
47705
|
setError(isValid2 || "You must provide a valid value");
|
|
47638
47706
|
setStatus("idle");
|
|
47639
47707
|
}
|
|
@@ -63977,7 +64045,7 @@ var import_follow_redirects = __toESM(require_follow_redirects(), 1);
|
|
|
63977
64045
|
var import_zlib = __toESM(require("zlib"), 1);
|
|
63978
64046
|
|
|
63979
64047
|
// node_modules/axios/lib/env/data.js
|
|
63980
|
-
var VERSION = "1.7.
|
|
64048
|
+
var VERSION = "1.7.9";
|
|
63981
64049
|
|
|
63982
64050
|
// node_modules/axios/lib/helpers/parseProtocol.js
|
|
63983
64051
|
function parseProtocol(url2) {
|
|
@@ -69703,7 +69771,9 @@ var ListExtensionSnapshotCommand = class {
|
|
|
69703
69771
|
} else {
|
|
69704
69772
|
const result = [];
|
|
69705
69773
|
for (const ver of versions) {
|
|
69706
|
-
result.push(
|
|
69774
|
+
result.push(
|
|
69775
|
+
`${ver.version}, ${ver.created}, ${ver.createdBy}, ${ver.notes || "no notes"}`
|
|
69776
|
+
);
|
|
69707
69777
|
}
|
|
69708
69778
|
task.output = result.join("\n");
|
|
69709
69779
|
}
|
|
@@ -69832,7 +69902,7 @@ var PublishCommand = class {
|
|
|
69832
69902
|
kongJson.name,
|
|
69833
69903
|
snapshot
|
|
69834
69904
|
);
|
|
69835
|
-
task.output = `
|
|
69905
|
+
task.output = `The version ${ctx.publishDetails.imageVersion} has been successfully published!`;
|
|
69836
69906
|
},
|
|
69837
69907
|
rendererOptions: defaultRendererOptions
|
|
69838
69908
|
}
|
package/package.json
CHANGED
|
@@ -1,136 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
-
"type": "object",
|
|
4
|
-
"properties": {
|
|
5
|
-
"id": {
|
|
6
|
-
"type": "string"
|
|
7
|
-
},
|
|
8
|
-
"name": {
|
|
9
|
-
"type": "string"
|
|
10
|
-
},
|
|
11
|
-
"ownership": {
|
|
12
|
-
"type": "array",
|
|
13
|
-
"items": {
|
|
14
|
-
"type": "string"
|
|
15
|
-
}
|
|
16
|
-
},
|
|
17
|
-
"sdk": {
|
|
18
|
-
"type": "string",
|
|
19
|
-
"enum": ["python", "kotlin"]
|
|
20
|
-
},
|
|
21
|
-
"alias": {
|
|
22
|
-
"type": "object",
|
|
23
|
-
"properties": {
|
|
24
|
-
"env": {
|
|
25
|
-
"type": "object",
|
|
26
|
-
"additionalProperties": true
|
|
27
|
-
},
|
|
28
|
-
"input": {
|
|
29
|
-
"type": "object",
|
|
30
|
-
"properties": {
|
|
31
|
-
"filter": {
|
|
32
|
-
"type": "string"
|
|
33
|
-
},
|
|
34
|
-
"schema": {
|
|
35
|
-
"$ref": "https://json-schema.org/draft-07/schema#"
|
|
36
|
-
}
|
|
37
|
-
},
|
|
38
|
-
"required": ["schema", "filter"]
|
|
39
|
-
},
|
|
40
|
-
"output": {
|
|
41
|
-
"type": "object",
|
|
42
|
-
"properties": {
|
|
43
|
-
"filter": {
|
|
44
|
-
"type": "string"
|
|
45
|
-
},
|
|
46
|
-
"schema": {
|
|
47
|
-
"$ref": "https://json-schema.org/draft-07/schema#"
|
|
48
|
-
}
|
|
49
|
-
},
|
|
50
|
-
"required": ["schema", "filter"]
|
|
51
|
-
},
|
|
52
|
-
"invoke": {
|
|
53
|
-
"type": "object",
|
|
54
|
-
"properties": {
|
|
55
|
-
"prefix": {
|
|
56
|
-
"type": "string"
|
|
57
|
-
},
|
|
58
|
-
"cache": {
|
|
59
|
-
"type": "object",
|
|
60
|
-
"properties": {
|
|
61
|
-
"enabled": {
|
|
62
|
-
"type": "boolean"
|
|
63
|
-
},
|
|
64
|
-
"key": {
|
|
65
|
-
"type": ["string"]
|
|
66
|
-
},
|
|
67
|
-
"ttl": {
|
|
68
|
-
"type": "string"
|
|
69
|
-
},
|
|
70
|
-
"onFailure": {
|
|
71
|
-
"type": "string",
|
|
72
|
-
"enum": ["skip", "retry"]
|
|
73
|
-
}
|
|
74
|
-
},
|
|
75
|
-
"required": ["enabled", "key", "ttl", "onFailure"]
|
|
76
|
-
},
|
|
77
|
-
"retry": {
|
|
78
|
-
"type": "object",
|
|
79
|
-
"properties": {
|
|
80
|
-
"maxAttempts": {
|
|
81
|
-
"type": "number"
|
|
82
|
-
},
|
|
83
|
-
"attemptDelay": {
|
|
84
|
-
"type": "string"
|
|
85
|
-
},
|
|
86
|
-
"attemptTimeout": {
|
|
87
|
-
"type": "string"
|
|
88
|
-
}
|
|
89
|
-
},
|
|
90
|
-
"required": ["maxAttempts", "attemptDelay", "attemptTimeout"]
|
|
91
|
-
},
|
|
92
|
-
"circuitBreaker": {
|
|
93
|
-
"type": "object",
|
|
94
|
-
"properties": {
|
|
95
|
-
"enabled": {
|
|
96
|
-
"type": "boolean"
|
|
97
|
-
},
|
|
98
|
-
"requestVolumeThreshold": {
|
|
99
|
-
"type": "number"
|
|
100
|
-
},
|
|
101
|
-
"failureRatio": {
|
|
102
|
-
"type": "number"
|
|
103
|
-
},
|
|
104
|
-
"successThreshold": {
|
|
105
|
-
"type": "number"
|
|
106
|
-
}
|
|
107
|
-
},
|
|
108
|
-
"required": ["enabled", "requestVolumeThreshold", "failureRatio", "successThreshold"]
|
|
109
|
-
},
|
|
110
|
-
"rateLimiter": {
|
|
111
|
-
"type": "object",
|
|
112
|
-
"properties": {
|
|
113
|
-
"enabled": {
|
|
114
|
-
"type": "boolean"
|
|
115
|
-
},
|
|
116
|
-
"value": {
|
|
117
|
-
"type": "number"
|
|
118
|
-
},
|
|
119
|
-
"window": {
|
|
120
|
-
"type": "string"
|
|
121
|
-
},
|
|
122
|
-
"minSpacing": {
|
|
123
|
-
"type": "string"
|
|
124
|
-
}
|
|
125
|
-
},
|
|
126
|
-
"required": ["enabled", "value", "window", "minSpacing"]
|
|
127
|
-
}
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
},
|
|
131
|
-
"additionalProperties": false
|
|
132
|
-
}
|
|
133
|
-
},
|
|
134
|
-
"additionalProperties": false,
|
|
135
|
-
"required": ["id", "name", "ownership", "sdk"]
|
|
136
|
-
}
|