@contrail/cli 2.0.11 → 2.0.13
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/install.js +4 -0
- package/dist/commands/projects/load.js +1 -1
- package/dist/commands/types/parseOptionSetsLocalFiles.js +1 -1
- package/dist/helpers/projects/helpers.js +3 -2
- package/dist/templates/typescript/app.yml +1 -1
- package/dist/templates/typescript/package.json +2 -2
- package/oclif.manifest.json +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -15,7 +15,7 @@ $ npm install -g @contrail/cli
|
|
|
15
15
|
$ contrail COMMAND
|
|
16
16
|
running command...
|
|
17
17
|
$ contrail (--version)
|
|
18
|
-
@contrail/cli/2.0.
|
|
18
|
+
@contrail/cli/2.0.13 darwin-arm64 node-v18.13.0
|
|
19
19
|
$ contrail --help [COMMAND]
|
|
20
20
|
USAGE
|
|
21
21
|
$ contrail COMMAND
|
|
@@ -35,6 +35,10 @@ class InstallApp extends core_1.Command {
|
|
|
35
35
|
flags.appIdentifier = answers.appIdentifier;
|
|
36
36
|
}
|
|
37
37
|
const app = installableApps.find(x => x.identifier === flags.appIdentifier);
|
|
38
|
+
if (!app) {
|
|
39
|
+
console.error(chalk_1.default.red.bold(`App ${flags.appIdentifier} not found`));
|
|
40
|
+
throw new Error(`App ${flags.appIdentifier} not found`);
|
|
41
|
+
}
|
|
38
42
|
let configProperties;
|
|
39
43
|
if (app.configProperties) {
|
|
40
44
|
configProperties = await getConfigProperties(app);
|
|
@@ -13,7 +13,7 @@ class LoadProject extends core_1.Command {
|
|
|
13
13
|
await (0, login_1.authUser)();
|
|
14
14
|
this.log('%s Parsing Template.', chalk_1.default.blue.bold('START'));
|
|
15
15
|
this.log('%s Uploading', chalk_1.default.yellow.bold('PROJECT'));
|
|
16
|
-
const templateFileLocation = args
|
|
16
|
+
const templateFileLocation = args.templateFileLocation;
|
|
17
17
|
this.log('Using Template File Location: ', args.templateFileLocation);
|
|
18
18
|
await uploadProject(templateFileLocation);
|
|
19
19
|
this.log('%s Uploaded', chalk_1.default.yellow.bold('PROJECT'));
|
|
@@ -44,7 +44,7 @@ async function ParseOptionSetsToFolderStructure(args) {
|
|
|
44
44
|
throw new Error('File name must be included.');
|
|
45
45
|
}
|
|
46
46
|
console.log('%s Importing local file', chalk_1.default.yellow.bold('OPTION SET PARSE'));
|
|
47
|
-
const fileLocation = args
|
|
47
|
+
const fileLocation = args.file;
|
|
48
48
|
console.log('Using File: ', fileLocation);
|
|
49
49
|
await parseOptionSetsToFolderStructure(fileLocation);
|
|
50
50
|
console.log('%s Parsed', chalk_1.default.yellow.bold('OPTION SET PARSE'));
|
|
@@ -51,16 +51,17 @@ async function getAssortmentsAndSubFolders(parentId, assortments, subFolders, al
|
|
|
51
51
|
workspaceId: parentId,
|
|
52
52
|
}
|
|
53
53
|
});
|
|
54
|
-
const integrationAssortments = workspaceAssortments
|
|
54
|
+
const integrationAssortments = workspaceAssortments; //?.filter(a => a.assortmentType === 'INTEGRATION');
|
|
55
55
|
if ((integrationAssortments === null || integrationAssortments === void 0 ? void 0 : integrationAssortments.length) > 0) {
|
|
56
56
|
allAssortments.push(...integrationAssortments);
|
|
57
57
|
for (const a of integrationAssortments) {
|
|
58
58
|
const integrationAssortmentsCopy = util_1.ObjectUtil.cloneDeep(a);
|
|
59
59
|
deleteNonUserKeys(integrationAssortmentsCopy);
|
|
60
|
+
const assortmentType = a.assortmentType === 'INTEGRATION' ? 'ASSORTMENT' : a.assortmentType;
|
|
60
61
|
const converted = {
|
|
61
62
|
identifier: a.identifier,
|
|
62
63
|
name: a.name,
|
|
63
|
-
type:
|
|
64
|
+
type: assortmentType,
|
|
64
65
|
sourceAssortmentIdentifier: [],
|
|
65
66
|
sourceAssortmentIds: a.sourceAssortmentIds,
|
|
66
67
|
composedFromAssortmentIdentifiers: [],
|
|
@@ -48,5 +48,5 @@ workflows:
|
|
|
48
48
|
# Here, you can define a string based on properties from the event payloads (which are custom to your payload)
|
|
49
49
|
# i.e. an event {details: {eventType: 'apparel'}, actionType: 'create'} can be parsed to apparel|create with the following
|
|
50
50
|
# When this is defined, any event coming from your app's credentials will define a trigger key using this logic.
|
|
51
|
-
# You can then define workflows to run based on those external events, based on this
|
|
51
|
+
# You can then define workflows to run based on those external events, based on this trigger key definition.
|
|
52
52
|
eventWorkflowTriggerKeyMapping: "{details.eventType}|{actionType}"
|
|
@@ -20,8 +20,8 @@
|
|
|
20
20
|
"lint": "eslint . --fix",
|
|
21
21
|
"test": "jest",
|
|
22
22
|
"test-watch": "jest --watch",
|
|
23
|
-
"docker-build": "docker build . -t \"${npm_package_name}:${npm_package_version}\"",
|
|
24
|
-
"docker-build:win": "docker build . -t \"%npm_package_name%:%npm_package_version%\"",
|
|
23
|
+
"docker-build": "docker build . -t \"${npm_package_name}:${npm_package_version}\" --platform=linux/amd64",
|
|
24
|
+
"docker-build:win": "docker build . -t \"%npm_package_name%:%npm_package_version%\" --platform=linux/amd64",
|
|
25
25
|
"docker-run-entry": "docker run -it --entrypoint=/bin/bash \"${npm_package_name}:${npm_package_version}\"",
|
|
26
26
|
"docker-run-entry:win": "docker run -it --entrypoint=/bin/bash \"%npm_package_name%:%npm_package_version%\"",
|
|
27
27
|
"docker-run": "docker run --env CONTRAIL_CLI_ENV=DEV -p 9000:8080 \"${npm_package_name}:${npm_package_version}\"",
|
package/oclif.manifest.json
CHANGED