contensis-cli 1.5.1-beta.9 → 1.6.0
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/CHANGELOG.md +35 -0
- package/README.md +41 -21
- package/cli.js +20 -0
- package/dist/localisation/en-GB.js +4 -2
- package/dist/localisation/en-GB.js.map +2 -2
- package/dist/services/ContensisCliService.js +8 -8
- package/dist/services/ContensisCliService.js.map +2 -2
- package/dist/version.js +1 -1
- package/dist/version.js.map +1 -1
- package/package.json +2 -2
- package/src/localisation/en-GB.ts +6 -3
- package/src/services/ContensisCliService.ts +4 -4
- package/src/version.ts +1 -1
package/dist/version.js
CHANGED
|
@@ -21,7 +21,7 @@ __export(version_exports, {
|
|
|
21
21
|
LIB_VERSION: () => LIB_VERSION
|
|
22
22
|
});
|
|
23
23
|
module.exports = __toCommonJS(version_exports);
|
|
24
|
-
const LIB_VERSION = "1.5.1-beta.
|
|
24
|
+
const LIB_VERSION = "1.5.1-beta.21";
|
|
25
25
|
// Annotate the CommonJS export names for ESM import in node:
|
|
26
26
|
0 && (module.exports = {
|
|
27
27
|
LIB_VERSION
|
package/dist/version.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../src/version.ts"],
|
|
4
|
-
"sourcesContent": ["export const LIB_VERSION = \"1.5.1-beta.
|
|
4
|
+
"sourcesContent": ["export const LIB_VERSION = \"1.5.1-beta.21\";\n"],
|
|
5
5
|
"mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAO,MAAM,cAAc;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "contensis-cli",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.6.0",
|
|
4
4
|
"description": "A fully featured Contensis command line interface with a shell UI provides simple and intuitive ways to manage or profile your content in any NodeJS terminal.",
|
|
5
5
|
"repository": "https://github.com/contensis/cli",
|
|
6
6
|
"homepage": "https://github.com/contensis/cli/tree/main/packages/contensis-cli#readme",
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"inquirer-command-prompt": "^0.1.0",
|
|
40
40
|
"keytar": "^7.9.0",
|
|
41
41
|
"lodash": "^4.17.21",
|
|
42
|
-
"migratortron": "^1.0.0-beta.
|
|
42
|
+
"migratortron": "^1.0.0-beta.84",
|
|
43
43
|
"nanospinner": "^1.2.0",
|
|
44
44
|
"node-fetch": "^2.6.7",
|
|
45
45
|
"parse-git-config": "^3.0.0",
|
|
@@ -124,8 +124,11 @@ export const LogMessages = {
|
|
|
124
124
|
entities: { [noun: string]: number }
|
|
125
125
|
) =>
|
|
126
126
|
`${commit ? `Imported` : `Will import`} ${Object.entries(entities)
|
|
127
|
-
.map(
|
|
128
|
-
|
|
127
|
+
.map(
|
|
128
|
+
([noun, count], i, arr) =>
|
|
129
|
+
`${i > 0 ? (i === arr.length - 1 ? ' and ' : ', ') : ''}${pl(noun, count, true)}`
|
|
130
|
+
)
|
|
131
|
+
.join('')} into ${env} environment`,
|
|
129
132
|
|
|
130
133
|
models: {
|
|
131
134
|
result: (
|
|
@@ -242,7 +245,7 @@ export const LogMessages = {
|
|
|
242
245
|
failedImport: (env: string) => `[${env}] Unable to import entries`,
|
|
243
246
|
update: {
|
|
244
247
|
preview: () => LogMessages.migrate.preview('UPDATE FIELD'),
|
|
245
|
-
commit: () => LogMessages.migrate.
|
|
248
|
+
commit: () => LogMessages.migrate.commit('FIELD UPDATES'),
|
|
246
249
|
success: (env: string, commit: boolean, entries: number, nodes = 0) =>
|
|
247
250
|
`${commit ? `Updated` : `Will update`} ${pl('entry', entries, true)}${
|
|
248
251
|
nodes > 0 ? ` and ${pl('node', nodes, true)}` : ''
|
|
@@ -1440,8 +1440,8 @@ class ContensisCli {
|
|
|
1440
1440
|
} else {
|
|
1441
1441
|
const noChanges =
|
|
1442
1442
|
result?.tagsToMigrate?.[currentProject]?.['no change'] &&
|
|
1443
|
-
result
|
|
1444
|
-
result
|
|
1443
|
+
result?.tagsToMigrate?.[currentProject].totalCount === 0 &&
|
|
1444
|
+
result?.groupsToMigrate?.[currentProject].totalCount === 0;
|
|
1445
1445
|
|
|
1446
1446
|
if (noChanges && !err && !result.errors?.length) {
|
|
1447
1447
|
log.help(messages.tags.noChange(currentEnv));
|
|
@@ -2425,10 +2425,10 @@ class ContensisCli {
|
|
|
2425
2425
|
}
|
|
2426
2426
|
} else {
|
|
2427
2427
|
const noChanges =
|
|
2428
|
-
Object.values(result?.entriesToMigrate?.[currentProject]).every(
|
|
2428
|
+
Object.values(result?.entriesToMigrate?.[currentProject] || {}).every(
|
|
2429
2429
|
status =>
|
|
2430
2430
|
typeof status === 'number' || (status['no change'] || 0) > 0
|
|
2431
|
-
) && result
|
|
2431
|
+
) && result?.entriesToMigrate?.[currentProject].totalCount === 0;
|
|
2432
2432
|
|
|
2433
2433
|
if (
|
|
2434
2434
|
noChanges &&
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const LIB_VERSION = "1.5.1-beta.
|
|
1
|
+
export const LIB_VERSION = "1.5.1-beta.21";
|