@contrail/cli 3.3.4 → 3.3.5
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/README.md +1 -1
- package/dist/commands/app/create.js +1 -14
- package/dist/commands/app/init.js +0 -14
- package/dist/commands/types/uploadUsageInfo.js +0 -2
- package/dist/helpers/app/setup-template.d.ts +0 -2
- package/dist/helpers/app/setup-template.js +1 -2
- package/dist/templates/typescript/app.yml +1 -1
- package/oclif.manifest.json +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -17,7 +17,7 @@ $ npm install -g @contrail/cli
|
|
|
17
17
|
$ contrail COMMAND
|
|
18
18
|
running command...
|
|
19
19
|
$ contrail (--version)
|
|
20
|
-
@contrail/cli/3.3.
|
|
20
|
+
@contrail/cli/3.3.5 darwin-arm64 node-v22.19.0
|
|
21
21
|
$ contrail --help [COMMAND]
|
|
22
22
|
USAGE
|
|
23
23
|
$ contrail COMMAND
|
|
@@ -27,7 +27,6 @@ class CreateApp extends basecommand_1.BaseCommand {
|
|
|
27
27
|
const defaultAppIdentifier = `@${username}/hello-world`;
|
|
28
28
|
const defaultAppDescription = `Hello world app by ${currentUser.email}`;
|
|
29
29
|
const defaultAppPublisher = `${currentUser.email}`;
|
|
30
|
-
const defaultNodeRuntime = entity_types_1.NodeRuntime.NODEJS_22_X;
|
|
31
30
|
const answers = await inquirer_1.default.prompt([
|
|
32
31
|
{
|
|
33
32
|
type: 'input',
|
|
@@ -57,17 +56,6 @@ class CreateApp extends basecommand_1.BaseCommand {
|
|
|
57
56
|
default: defaultAppPublisher,
|
|
58
57
|
required: true,
|
|
59
58
|
},
|
|
60
|
-
{
|
|
61
|
-
type: 'list',
|
|
62
|
-
name: 'nodeRuntime',
|
|
63
|
-
message: 'Select the Node.js runtime for your app:',
|
|
64
|
-
choices: [
|
|
65
|
-
{ name: 'Node.js 22.x (recommended)', value: entity_types_1.NodeRuntime.NODEJS_22_X },
|
|
66
|
-
{ name: 'Node.js 18.x (deprecated)', value: entity_types_1.NodeRuntime.NODEJS_18_X },
|
|
67
|
-
],
|
|
68
|
-
default: defaultNodeRuntime,
|
|
69
|
-
required: true,
|
|
70
|
-
},
|
|
71
59
|
]);
|
|
72
60
|
let sanitizedIdentifier = answers.appIdentifier;
|
|
73
61
|
if (!sanitizedIdentifier.startsWith('@')) {
|
|
@@ -81,7 +69,7 @@ class CreateApp extends basecommand_1.BaseCommand {
|
|
|
81
69
|
public: false,
|
|
82
70
|
description: answers.appDescription,
|
|
83
71
|
frameworkVersion: 2,
|
|
84
|
-
nodeRuntime:
|
|
72
|
+
nodeRuntime: entity_types_1.NodeRuntime.NODEJS_22_X,
|
|
85
73
|
};
|
|
86
74
|
try {
|
|
87
75
|
await new sdk_1.Entities().create({ entityName: 'app', object: newApp });
|
|
@@ -95,7 +83,6 @@ class CreateApp extends basecommand_1.BaseCommand {
|
|
|
95
83
|
appIdentifier: sanitizedIdentifier,
|
|
96
84
|
appDescription: answers.appDescription,
|
|
97
85
|
appPublisher: answers.appPublisher,
|
|
98
|
-
nodeRuntime: answers.nodeRuntime,
|
|
99
86
|
});
|
|
100
87
|
try {
|
|
101
88
|
let appDeclaration = (0, load_app_config_1.loadAppConfig)();
|
|
@@ -6,7 +6,6 @@ const login_1 = require("../../auth/login");
|
|
|
6
6
|
const basecommand_1 = require("../../basecommand");
|
|
7
7
|
const setup_template_1 = require("../../helpers/app/setup-template");
|
|
8
8
|
const sdk_1 = require("@contrail/sdk");
|
|
9
|
-
const entity_types_1 = require("@contrail/entity-types");
|
|
10
9
|
class InitApp extends basecommand_1.BaseCommand {
|
|
11
10
|
static description = 'Initialize an app directory from a template';
|
|
12
11
|
static examples = [
|
|
@@ -24,7 +23,6 @@ class InitApp extends basecommand_1.BaseCommand {
|
|
|
24
23
|
const defaultAppIdentifier = `@${username}/hello-world`;
|
|
25
24
|
const defaultAppDescription = `Hello world app by ${currentUser.email}`;
|
|
26
25
|
const defaultAppPublisher = `${currentUser.email}`;
|
|
27
|
-
const defaultNodeRuntime = entity_types_1.NodeRuntime.NODEJS_22_X;
|
|
28
26
|
const answers = await inquirer_1.default.prompt([
|
|
29
27
|
{
|
|
30
28
|
type: 'input',
|
|
@@ -54,17 +52,6 @@ class InitApp extends basecommand_1.BaseCommand {
|
|
|
54
52
|
default: defaultAppPublisher,
|
|
55
53
|
required: true,
|
|
56
54
|
},
|
|
57
|
-
{
|
|
58
|
-
type: 'list',
|
|
59
|
-
name: 'nodeRuntime',
|
|
60
|
-
message: 'Select the Node.js runtime for your app:',
|
|
61
|
-
choices: [
|
|
62
|
-
{ name: 'Node.js 22.x (recommended)', value: entity_types_1.NodeRuntime.NODEJS_22_X },
|
|
63
|
-
{ name: 'Node.js 18.x (deprecated)', value: entity_types_1.NodeRuntime.NODEJS_18_X },
|
|
64
|
-
],
|
|
65
|
-
default: defaultNodeRuntime,
|
|
66
|
-
required: true,
|
|
67
|
-
},
|
|
68
55
|
]);
|
|
69
56
|
let sanitizedIdentifier = answers.appIdentifier;
|
|
70
57
|
if (!sanitizedIdentifier.startsWith('@')) {
|
|
@@ -75,7 +62,6 @@ class InitApp extends basecommand_1.BaseCommand {
|
|
|
75
62
|
appIdentifier: sanitizedIdentifier,
|
|
76
63
|
appDescription: answers.appDescription,
|
|
77
64
|
appPublisher: answers.appPublisher,
|
|
78
|
-
nodeRuntime: answers.nodeRuntime,
|
|
79
65
|
});
|
|
80
66
|
}
|
|
81
67
|
}
|
|
@@ -103,7 +103,6 @@ async function uploadUsageInfoObjects(loadedUsageInfo) {
|
|
|
103
103
|
numberFormat: loadedUI.numberFormat,
|
|
104
104
|
defaultValue: loadedUI.defaultValue,
|
|
105
105
|
label: loadedUI.label,
|
|
106
|
-
isArchived: loadedUI.isArchived,
|
|
107
106
|
},
|
|
108
107
|
});
|
|
109
108
|
}
|
|
@@ -130,7 +129,6 @@ async function uploadUsageInfoObjects(loadedUsageInfo) {
|
|
|
130
129
|
copyBehavior: loadedUI?.copyBehavior,
|
|
131
130
|
copyDefault: loadedUI?.copyDefault,
|
|
132
131
|
propertyLevel: loadedUI?.propertyLevel,
|
|
133
|
-
isArchived: loadedUI?.isArchived,
|
|
134
132
|
},
|
|
135
133
|
});
|
|
136
134
|
}
|
|
@@ -1,10 +1,8 @@
|
|
|
1
|
-
import { NodeRuntime } from '@contrail/entity-types';
|
|
2
1
|
interface AppSetUpInputs {
|
|
3
2
|
appName: string;
|
|
4
3
|
appIdentifier: string;
|
|
5
4
|
appDescription: string;
|
|
6
5
|
appPublisher: string;
|
|
7
|
-
nodeRuntime: NodeRuntime;
|
|
8
6
|
}
|
|
9
7
|
export declare function setUpTemplate(appInput: AppSetUpInputs): Promise<void>;
|
|
10
8
|
export {};
|
|
@@ -38,8 +38,7 @@ async function setUpTemplate(appInput) {
|
|
|
38
38
|
.replace(/APP_IDENTIFIER_STUB/g, appInput.appIdentifier)
|
|
39
39
|
.replace(/APP_NAME_STUB/g, appInput.appName)
|
|
40
40
|
.replace(/APP_DESCRIPTION_STUB/g, appInput.appDescription)
|
|
41
|
-
.replace(/APP_PUBLISHER_STUB/g, appInput.appPublisher)
|
|
42
|
-
.replace(/NODE_RUNTIME_STUB/g, appInput.nodeRuntime);
|
|
41
|
+
.replace(/APP_PUBLISHER_STUB/g, appInput.appPublisher);
|
|
43
42
|
fs_1.default.writeFileSync(appYmlFileLoc, newAppYml);
|
|
44
43
|
}
|
|
45
44
|
catch (e) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
appIdentifier: 'APP_IDENTIFIER_STUB' # Change to be your company root domain and the name of the app
|
|
2
2
|
appName: 'APP_NAME_STUB' # Give your app a name
|
|
3
3
|
appDescription: 'APP_DESCRIPTION_STUB' # Give your app a description
|
|
4
|
-
nodeRuntime: '
|
|
4
|
+
nodeRuntime: 'nodejs22.x' # The Node.js runtime version to use for your app
|
|
5
5
|
visibility: private # This should be private unless you want to develop an app for all VibeIQ customers to use
|
|
6
6
|
# Access Grants
|
|
7
7
|
# Use this section to share this app with other organizations.
|
package/oclif.manifest.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@contrail/cli",
|
|
3
|
-
"version": "3.3.
|
|
3
|
+
"version": "3.3.5",
|
|
4
4
|
"description": "VibeIQ's Contrail Platform CLI.",
|
|
5
5
|
"bin": {
|
|
6
6
|
"contrail-cli": "./bin/run",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
],
|
|
24
24
|
"dependencies": {
|
|
25
25
|
"@contrail/entity-types": "^1.3.0",
|
|
26
|
-
"@contrail/org-config-migration": "^1.1.
|
|
26
|
+
"@contrail/org-config-migration": "^1.1.6",
|
|
27
27
|
"@contrail/sdk": "^1.4.6",
|
|
28
28
|
"@contrail/types": "^3.0.48",
|
|
29
29
|
"@contrail/util": "^1.1.10",
|