@contentstack/cli-config 1.8.0 → 1.9.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/README.md +20 -18
- package/lib/commands/config/remove/base-branch.js +2 -2
- package/lib/commands/config/remove/early-access-header.js +2 -2
- package/lib/commands/config/set/base-branch.js +2 -2
- package/lib/commands/config/set/early-access-header.js +2 -2
- package/lib/commands/config/set/region.js +5 -5
- package/lib/utils/region-handler.js +1 -1
- package/oclif.manifest.json +14 -14
- package/package.json +18 -28
package/README.md
CHANGED
|
@@ -18,7 +18,7 @@ $ npm install -g @contentstack/cli-config
|
|
|
18
18
|
$ csdx COMMAND
|
|
19
19
|
running command...
|
|
20
20
|
$ csdx (--version)
|
|
21
|
-
@contentstack/cli-config/1.
|
|
21
|
+
@contentstack/cli-config/1.9.1 linux-x64 node-v18.20.6
|
|
22
22
|
$ csdx --help [COMMAND]
|
|
23
23
|
USAGE
|
|
24
24
|
$ csdx COMMAND
|
|
@@ -142,8 +142,8 @@ USAGE
|
|
|
142
142
|
$ csdx config:remove:base-branch [-k <value>] [-y]
|
|
143
143
|
|
|
144
144
|
FLAGS
|
|
145
|
-
-k, --stack-api-key=<value> Stack API
|
|
146
|
-
-y, --yes Force
|
|
145
|
+
-k, --stack-api-key=<value> Stack API key.
|
|
146
|
+
-y, --yes Force remove.
|
|
147
147
|
|
|
148
148
|
DESCRIPTION
|
|
149
149
|
Remove branch config for CLI
|
|
@@ -165,8 +165,9 @@ USAGE
|
|
|
165
165
|
$ csdx config:remove:ea-header [--header-alias <value>] [-y]
|
|
166
166
|
|
|
167
167
|
FLAGS
|
|
168
|
-
-y, --yes Force
|
|
169
|
-
|
|
168
|
+
-y, --yes (optional) Force the removal of Early Access header configuration by skipping the
|
|
169
|
+
confirmation.
|
|
170
|
+
--header-alias=<value> (optional) Provide the Early Access header alias name.
|
|
170
171
|
|
|
171
172
|
DESCRIPTION
|
|
172
173
|
Remove Early Access header
|
|
@@ -189,8 +190,9 @@ USAGE
|
|
|
189
190
|
$ csdx config:remove:early-access-header [--header-alias <value>] [-y]
|
|
190
191
|
|
|
191
192
|
FLAGS
|
|
192
|
-
-y, --yes Force
|
|
193
|
-
|
|
193
|
+
-y, --yes (optional) Force the removal of Early Access header configuration by skipping the
|
|
194
|
+
confirmation.
|
|
195
|
+
--header-alias=<value> (optional) Provide the Early Access header alias name.
|
|
194
196
|
|
|
195
197
|
DESCRIPTION
|
|
196
198
|
Remove Early Access header
|
|
@@ -235,8 +237,8 @@ USAGE
|
|
|
235
237
|
$ csdx config:set:base-branch [-k <value>] [--base-branch <value>]
|
|
236
238
|
|
|
237
239
|
FLAGS
|
|
238
|
-
-k, --stack-api-key=<value> Stack API
|
|
239
|
-
--base-branch=<value> Base
|
|
240
|
+
-k, --stack-api-key=<value> Stack API key
|
|
241
|
+
--base-branch=<value> Base branch (Target branch).
|
|
240
242
|
|
|
241
243
|
DESCRIPTION
|
|
242
244
|
Set branch for CLI
|
|
@@ -258,8 +260,8 @@ USAGE
|
|
|
258
260
|
$ csdx config:set:ea-header [--header-alias <value>] [--header <value>]
|
|
259
261
|
|
|
260
262
|
FLAGS
|
|
261
|
-
--header=<value> Early
|
|
262
|
-
--header-alias=<value> Early
|
|
263
|
+
--header=<value> (optional) Provide the Early Access header alias name.
|
|
264
|
+
--header-alias=<value> (optional) Provide the Early Access header value.
|
|
263
265
|
|
|
264
266
|
DESCRIPTION
|
|
265
267
|
Set Early Access header
|
|
@@ -282,8 +284,8 @@ USAGE
|
|
|
282
284
|
$ csdx config:set:early-access-header [--header-alias <value>] [--header <value>]
|
|
283
285
|
|
|
284
286
|
FLAGS
|
|
285
|
-
--header=<value> Early
|
|
286
|
-
--header-alias=<value> Early
|
|
287
|
+
--header=<value> (optional) Provide the Early Access header alias name.
|
|
288
|
+
--header-alias=<value> (optional) Provide the Early Access header value.
|
|
287
289
|
|
|
288
290
|
DESCRIPTION
|
|
289
291
|
Set Early Access header
|
|
@@ -366,15 +368,15 @@ EXAMPLES
|
|
|
366
368
|
|
|
367
369
|
$ csdx config:set:region GCP-NA
|
|
368
370
|
|
|
369
|
-
$ csdx config:set:region --cma <
|
|
371
|
+
$ csdx config:set:region --cma <custom_cma_host_url> --cda <custom_cda_host_url> --ui-host <custom_ui_host_url> --name "India"
|
|
370
372
|
|
|
371
|
-
$ csdx config:set:region --cma <
|
|
373
|
+
$ csdx config:set:region --cma <custom_cma_host_url> --cda <custom_cda_host_url> --ui-host <custom_ui_host_url> --name "India" --developer-hub <custom_developer_hub_url>
|
|
372
374
|
|
|
373
|
-
$ csdx config:set:region --cma <
|
|
375
|
+
$ csdx config:set:region --cma <custom_cma_host_url> --cda <custom_cda_host_url> --ui-host <custom_ui_host_url> --name "India" --personalize <custom_personalize_url>
|
|
374
376
|
|
|
375
|
-
$ csdx config:set:region --cma <
|
|
377
|
+
$ csdx config:set:region --cma <custom_cma_host_url> --cda <custom_cda_host_url> --ui-host <custom_ui_host_url> --name "India" --launch <custom_launch_url>
|
|
376
378
|
|
|
377
|
-
$ csdx config:set:region --cda <
|
|
379
|
+
$ csdx config:set:region --cda <custom_cda_host_url> --cma <custom_cma_host_url> --ui-host <custom_ui_host_url> --name "India" --developer-hub <custom_developer_hub_url> --launch <custom_launch_url> --personalize <custom_personalize_url>
|
|
378
380
|
```
|
|
379
381
|
|
|
380
382
|
_See code: [src/commands/config/set/region.ts](https://github.com/contentstack/cli/blob/main/packages/contentstack-config/src/commands/config/set/region.ts)_
|
|
@@ -43,7 +43,7 @@ class RemoveBranchConfigCommand extends cli_command_1.Command {
|
|
|
43
43
|
exports.default = RemoveBranchConfigCommand;
|
|
44
44
|
RemoveBranchConfigCommand.description = 'Remove branch config for CLI';
|
|
45
45
|
RemoveBranchConfigCommand.flags = {
|
|
46
|
-
'stack-api-key': cli_utilities_1.flags.string({ char: 'k', description: 'Stack API
|
|
47
|
-
yes: cli_utilities_1.flags.boolean({ char: 'y', description: 'Force
|
|
46
|
+
'stack-api-key': cli_utilities_1.flags.string({ char: 'k', description: 'Stack API key.' }),
|
|
47
|
+
yes: cli_utilities_1.flags.boolean({ char: 'y', description: 'Force remove.' }),
|
|
48
48
|
};
|
|
49
49
|
RemoveBranchConfigCommand.examples = ['$ csdx config:remove:base-branch', '$ csdx config:remove:base-branch --stack-api-key <value>'];
|
|
@@ -32,8 +32,8 @@ exports.default = RemoveEarlyAccessHeader;
|
|
|
32
32
|
RemoveEarlyAccessHeader.description = 'Remove Early Access header';
|
|
33
33
|
RemoveEarlyAccessHeader.aliases = ['config:remove:ea-header'];
|
|
34
34
|
RemoveEarlyAccessHeader.flags = {
|
|
35
|
-
'header-alias': cli_utilities_1.flags.string({ description: 'Early
|
|
36
|
-
yes: cli_utilities_1.flags.boolean({ char: 'y', description: 'Force
|
|
35
|
+
'header-alias': cli_utilities_1.flags.string({ description: '(optional) Provide the Early Access header alias name.' }),
|
|
36
|
+
yes: cli_utilities_1.flags.boolean({ char: 'y', description: '(optional) Force the removal of Early Access header configuration by skipping the confirmation.' }),
|
|
37
37
|
};
|
|
38
38
|
RemoveEarlyAccessHeader.examples = [
|
|
39
39
|
'$ <%= config.bin %> <%= command.id %>',
|
|
@@ -28,8 +28,8 @@ class BranchSetCommand extends cli_command_1.Command {
|
|
|
28
28
|
exports.default = BranchSetCommand;
|
|
29
29
|
BranchSetCommand.description = 'Set branch for CLI';
|
|
30
30
|
BranchSetCommand.flags = {
|
|
31
|
-
'stack-api-key': cli_utilities_1.flags.string({ char: 'k', description: 'Stack API
|
|
32
|
-
'base-branch': cli_utilities_1.flags.string({ description: 'Base
|
|
31
|
+
'stack-api-key': cli_utilities_1.flags.string({ char: 'k', description: 'Stack API key' }),
|
|
32
|
+
'base-branch': cli_utilities_1.flags.string({ description: 'Base branch (Target branch).' }),
|
|
33
33
|
};
|
|
34
34
|
BranchSetCommand.examples = [
|
|
35
35
|
'$ csdx config:set:base-branch',
|
|
@@ -26,8 +26,8 @@ exports.default = SetEarlyAccessHeaderCommand;
|
|
|
26
26
|
SetEarlyAccessHeaderCommand.description = 'Set Early Access header';
|
|
27
27
|
SetEarlyAccessHeaderCommand.aliases = ['config:set:ea-header'];
|
|
28
28
|
SetEarlyAccessHeaderCommand.flags = {
|
|
29
|
-
'header-alias': cli_utilities_1.flags.string({ description: 'Early
|
|
30
|
-
header: cli_utilities_1.flags.string({ description: 'Early
|
|
29
|
+
'header-alias': cli_utilities_1.flags.string({ description: '(optional) Provide the Early Access header value.' }),
|
|
30
|
+
header: cli_utilities_1.flags.string({ description: '(optional) Provide the Early Access header alias name.' }),
|
|
31
31
|
};
|
|
32
32
|
SetEarlyAccessHeaderCommand.examples = [
|
|
33
33
|
'$ <%= config.bin %> <%= command.id %>',
|
|
@@ -121,11 +121,11 @@ RegionSetCommand.examples = [
|
|
|
121
121
|
'$ csdx config:set:region AZURE-NA',
|
|
122
122
|
'$ csdx config:set:region AZURE-EU',
|
|
123
123
|
'$ csdx config:set:region GCP-NA',
|
|
124
|
-
'$ csdx config:set:region --cma <
|
|
125
|
-
'$ csdx config:set:region --cma <
|
|
126
|
-
'$ csdx config:set:region --cma <
|
|
127
|
-
'$ csdx config:set:region --cma <
|
|
128
|
-
'$ csdx config:set:region --cda <
|
|
124
|
+
'$ csdx config:set:region --cma <custom_cma_host_url> --cda <custom_cda_host_url> --ui-host <custom_ui_host_url> --name "India"',
|
|
125
|
+
'$ csdx config:set:region --cma <custom_cma_host_url> --cda <custom_cda_host_url> --ui-host <custom_ui_host_url> --name "India" --developer-hub <custom_developer_hub_url>',
|
|
126
|
+
'$ csdx config:set:region --cma <custom_cma_host_url> --cda <custom_cda_host_url> --ui-host <custom_ui_host_url> --name "India" --personalize <custom_personalize_url>',
|
|
127
|
+
'$ csdx config:set:region --cma <custom_cma_host_url> --cda <custom_cda_host_url> --ui-host <custom_ui_host_url> --name "India" --launch <custom_launch_url>',
|
|
128
|
+
'$ csdx config:set:region --cda <custom_cda_host_url> --cma <custom_cma_host_url> --ui-host <custom_ui_host_url> --name "India" --developer-hub <custom_developer_hub_url> --launch <custom_launch_url> --personalize <custom_personalize_url>',
|
|
129
129
|
];
|
|
130
130
|
RegionSetCommand.args = {
|
|
131
131
|
region: cli_utilities_1.args.string({ description: 'Name for the region' }),
|
|
@@ -56,7 +56,7 @@ const regions = {
|
|
|
56
56
|
uiHost: 'https://gcp-na-app.contentstack.com',
|
|
57
57
|
name: 'GCP-NA',
|
|
58
58
|
'developerHubUrl': 'https://gcp-na-developerhub-api.contentstack.com',
|
|
59
|
-
'launchHubUrl': '
|
|
59
|
+
'launchHubUrl': 'https://gcp-na-launch-api.contentstack.com',
|
|
60
60
|
'personalizeUrl': 'https://gcp-na-personalize-api.contentstack.com',
|
|
61
61
|
},
|
|
62
62
|
};
|
package/oclif.manifest.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "1.
|
|
2
|
+
"version": "1.9.1",
|
|
3
3
|
"commands": {
|
|
4
4
|
"config:get:base-branch": {
|
|
5
5
|
"id": "config:get:base-branch",
|
|
@@ -81,14 +81,14 @@
|
|
|
81
81
|
"name": "stack-api-key",
|
|
82
82
|
"type": "option",
|
|
83
83
|
"char": "k",
|
|
84
|
-
"description": "Stack API
|
|
84
|
+
"description": "Stack API key.",
|
|
85
85
|
"multiple": false
|
|
86
86
|
},
|
|
87
87
|
"yes": {
|
|
88
88
|
"name": "yes",
|
|
89
89
|
"type": "boolean",
|
|
90
90
|
"char": "y",
|
|
91
|
-
"description": "Force
|
|
91
|
+
"description": "Force remove.",
|
|
92
92
|
"allowNo": false
|
|
93
93
|
}
|
|
94
94
|
},
|
|
@@ -113,14 +113,14 @@
|
|
|
113
113
|
"header-alias": {
|
|
114
114
|
"name": "header-alias",
|
|
115
115
|
"type": "option",
|
|
116
|
-
"description": "Early
|
|
116
|
+
"description": "(optional) Provide the Early Access header alias name.",
|
|
117
117
|
"multiple": false
|
|
118
118
|
},
|
|
119
119
|
"yes": {
|
|
120
120
|
"name": "yes",
|
|
121
121
|
"type": "boolean",
|
|
122
122
|
"char": "y",
|
|
123
|
-
"description": "Force
|
|
123
|
+
"description": "(optional) Force the removal of Early Access header configuration by skipping the confirmation.",
|
|
124
124
|
"allowNo": false
|
|
125
125
|
}
|
|
126
126
|
},
|
|
@@ -166,13 +166,13 @@
|
|
|
166
166
|
"name": "stack-api-key",
|
|
167
167
|
"type": "option",
|
|
168
168
|
"char": "k",
|
|
169
|
-
"description": "Stack API
|
|
169
|
+
"description": "Stack API key",
|
|
170
170
|
"multiple": false
|
|
171
171
|
},
|
|
172
172
|
"base-branch": {
|
|
173
173
|
"name": "base-branch",
|
|
174
174
|
"type": "option",
|
|
175
|
-
"description": "Base
|
|
175
|
+
"description": "Base branch (Target branch).",
|
|
176
176
|
"multiple": false
|
|
177
177
|
}
|
|
178
178
|
},
|
|
@@ -197,13 +197,13 @@
|
|
|
197
197
|
"header-alias": {
|
|
198
198
|
"name": "header-alias",
|
|
199
199
|
"type": "option",
|
|
200
|
-
"description": "Early
|
|
200
|
+
"description": "(optional) Provide the Early Access header value.",
|
|
201
201
|
"multiple": false
|
|
202
202
|
},
|
|
203
203
|
"header": {
|
|
204
204
|
"name": "header",
|
|
205
205
|
"type": "option",
|
|
206
|
-
"description": "Early
|
|
206
|
+
"description": "(optional) Provide the Early Access header alias name.",
|
|
207
207
|
"multiple": false
|
|
208
208
|
}
|
|
209
209
|
},
|
|
@@ -268,11 +268,11 @@
|
|
|
268
268
|
"$ csdx config:set:region AZURE-NA",
|
|
269
269
|
"$ csdx config:set:region AZURE-EU",
|
|
270
270
|
"$ csdx config:set:region GCP-NA",
|
|
271
|
-
"$ csdx config:set:region --cma <
|
|
272
|
-
"$ csdx config:set:region --cma <
|
|
273
|
-
"$ csdx config:set:region --cma <
|
|
274
|
-
"$ csdx config:set:region --cma <
|
|
275
|
-
"$ csdx config:set:region --cda <
|
|
271
|
+
"$ csdx config:set:region --cma <custom_cma_host_url> --cda <custom_cda_host_url> --ui-host <custom_ui_host_url> --name \"India\"",
|
|
272
|
+
"$ csdx config:set:region --cma <custom_cma_host_url> --cda <custom_cda_host_url> --ui-host <custom_ui_host_url> --name \"India\" --developer-hub <custom_developer_hub_url>",
|
|
273
|
+
"$ csdx config:set:region --cma <custom_cma_host_url> --cda <custom_cda_host_url> --ui-host <custom_ui_host_url> --name \"India\" --personalize <custom_personalize_url>",
|
|
274
|
+
"$ csdx config:set:region --cma <custom_cma_host_url> --cda <custom_cda_host_url> --ui-host <custom_ui_host_url> --name \"India\" --launch <custom_launch_url>",
|
|
275
|
+
"$ csdx config:set:region --cda <custom_cda_host_url> --cma <custom_cma_host_url> --ui-host <custom_ui_host_url> --name \"India\" --developer-hub <custom_developer_hub_url> --launch <custom_launch_url> --personalize <custom_personalize_url>"
|
|
276
276
|
],
|
|
277
277
|
"flags": {
|
|
278
278
|
"cda": {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@contentstack/cli-config",
|
|
3
3
|
"description": "Contentstack CLI plugin for configuration",
|
|
4
|
-
"version": "1.
|
|
4
|
+
"version": "1.9.1",
|
|
5
5
|
"author": "Contentstack",
|
|
6
6
|
"scripts": {
|
|
7
7
|
"build": "npm run clean && npm run compile",
|
|
@@ -21,36 +21,26 @@
|
|
|
21
21
|
"test:unit:report": "nyc --extension .ts mocha --forbid-only \"test/unit/**/*.test.ts\""
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@contentstack/cli-command": "~1.3.
|
|
25
|
-
"@contentstack/cli-utilities": "~1.8.
|
|
26
|
-
"
|
|
27
|
-
"debug": "^4.1.1",
|
|
28
|
-
"inquirer": "8.2.4",
|
|
29
|
-
"lodash": "^4.17.20",
|
|
30
|
-
"mkdirp": "^1.0.4",
|
|
31
|
-
"winston": "^3.7.2"
|
|
24
|
+
"@contentstack/cli-command": "~1.3.3",
|
|
25
|
+
"@contentstack/cli-utilities": "~1.8.1",
|
|
26
|
+
"lodash": "^4.17.21"
|
|
32
27
|
},
|
|
33
28
|
"devDependencies": {
|
|
34
|
-
"@oclif/test": "^
|
|
35
|
-
"@types/chai": "^4.
|
|
36
|
-
"@types/
|
|
37
|
-
"@types/
|
|
38
|
-
"@types/
|
|
39
|
-
"
|
|
40
|
-
"
|
|
41
|
-
"chai": "^4.3.4",
|
|
42
|
-
"eslint": "^8.18.0",
|
|
29
|
+
"@oclif/test": "^4.1.6",
|
|
30
|
+
"@types/chai": "^4.3.20",
|
|
31
|
+
"@types/mocha": "^8.2.3",
|
|
32
|
+
"@types/node": "^14.18.63",
|
|
33
|
+
"@types/sinon": "^10.0.20",
|
|
34
|
+
"chai": "^4.5.0",
|
|
35
|
+
"eslint": "^8.57.1",
|
|
43
36
|
"eslint-config-oclif": "^4.0.0",
|
|
44
|
-
"eslint-config-oclif-typescript": "^3.
|
|
45
|
-
"
|
|
46
|
-
"mocha": "10.1.0",
|
|
37
|
+
"eslint-config-oclif-typescript": "^3.1.13",
|
|
38
|
+
"mocha": "10.8.2",
|
|
47
39
|
"nyc": "^15.1.0",
|
|
48
|
-
"oclif": "^3.
|
|
49
|
-
"
|
|
50
|
-
"
|
|
51
|
-
"
|
|
52
|
-
"ts-node": "^10.9.1",
|
|
53
|
-
"typescript": "^4.9.3"
|
|
40
|
+
"oclif": "^3.17.2",
|
|
41
|
+
"sinon": "^19.0.2",
|
|
42
|
+
"ts-node": "^10.9.2",
|
|
43
|
+
"typescript": "^4.9.5"
|
|
54
44
|
},
|
|
55
45
|
"engines": {
|
|
56
46
|
"node": ">=14.0.0"
|
|
@@ -88,4 +78,4 @@
|
|
|
88
78
|
}
|
|
89
79
|
},
|
|
90
80
|
"repository": "contentstack/cli"
|
|
91
|
-
}
|
|
81
|
+
}
|