From 8473211001cceb03c26174916a75205eff652dd1 Mon Sep 17 00:00:00 2001 From: Vikram Kalta Date: Thu, 28 Sep 2023 13:00:47 +0100 Subject: [PATCH 01/41] fix(import): fixed stack inaccessible issue --- packages/contentstack-import/src/import/module-importer.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/contentstack-import/src/import/module-importer.ts b/packages/contentstack-import/src/import/module-importer.ts index 36551d16d0..030f2e5243 100755 --- a/packages/contentstack-import/src/import/module-importer.ts +++ b/packages/contentstack-import/src/import/module-importer.ts @@ -37,8 +37,8 @@ class ModuleImporter { }, }); - if (data.error_code === 161) { - throw new Error(data.error_message); + if ([161, 105].includes(data.error_code)) { + throw new Error(data.error_code === 105 ? 'Sorry but you don\'t have access to this stack' : data.error_message); } if (!this.importConfig.master_locale) { From 754dbd93c0855387ba137e92481baa633581c426 Mon Sep 17 00:00:00 2001 From: Vikram Kalta Date: Thu, 5 Oct 2023 13:16:03 +0100 Subject: [PATCH 02/41] fix: updated version --- package-lock.json | 2 +- packages/contentstack-import/package.json | 2 +- pnpm-lock.yaml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package-lock.json b/package-lock.json index 8ac7a4dd98..a7fd24a91d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -24178,7 +24178,7 @@ }, "packages/contentstack-import": { "name": "@contentstack/cli-cm-import", - "version": "1.9.0", + "version": "1.9.1", "license": "MIT", "dependencies": { "@contentstack/cli-command": "~1.2.12", diff --git a/packages/contentstack-import/package.json b/packages/contentstack-import/package.json index f92f51477c..c77d3651c0 100644 --- a/packages/contentstack-import/package.json +++ b/packages/contentstack-import/package.json @@ -1,7 +1,7 @@ { "name": "@contentstack/cli-cm-import", "description": "Contentstack CLI plugin to import content into stack", - "version": "1.9.0", + "version": "1.9.1", "author": "Contentstack", "bugs": "https://github.com/contentstack/cli/issues", "dependencies": { diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 71c060cd31..f77a2dacca 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -17,7 +17,7 @@ importers: '@contentstack/cli-cm-clone': ~1.5.0 '@contentstack/cli-cm-export': ~1.9.0 '@contentstack/cli-cm-export-to-csv': ~1.4.2 - '@contentstack/cli-cm-import': ~1.9.0 + '@contentstack/cli-cm-import': ~1.9.1 '@contentstack/cli-cm-migrate-rte': ~1.4.11 '@contentstack/cli-cm-seed': ~1.5.0 '@contentstack/cli-command': ~1.2.12 From 798ccc25f8b3500329cdcad54b19bdd4db1a18b1 Mon Sep 17 00:00:00 2001 From: Vikram Kalta Date: Fri, 6 Oct 2023 12:04:17 +0100 Subject: [PATCH 03/41] fix: updated version --- package-lock.json | 2 +- packages/contentstack-import/package.json | 2 +- pnpm-lock.yaml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package-lock.json b/package-lock.json index 071561e287..b6d109bc10 100644 --- a/package-lock.json +++ b/package-lock.json @@ -24423,7 +24423,7 @@ }, "packages/contentstack-import": { "name": "@contentstack/cli-cm-import", - "version": "1.9.1", + "version": "1.9.2", "license": "MIT", "dependencies": { "@contentstack/cli-command": "~1.2.13", diff --git a/packages/contentstack-import/package.json b/packages/contentstack-import/package.json index 001d5b5000..65667a586f 100644 --- a/packages/contentstack-import/package.json +++ b/packages/contentstack-import/package.json @@ -1,7 +1,7 @@ { "name": "@contentstack/cli-cm-import", "description": "Contentstack CLI plugin to import content into stack", - "version": "1.9.1", + "version": "1.9.2", "author": "Contentstack", "bugs": "https://github.com/contentstack/cli/issues", "dependencies": { diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 8bb2c1460a..638ea7df43 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -18,7 +18,7 @@ importers: '@contentstack/cli-cm-clone': ~1.5.1 '@contentstack/cli-cm-export': ~1.9.1 '@contentstack/cli-cm-export-to-csv': ~1.4.3 - '@contentstack/cli-cm-import': ~1.9.1 + '@contentstack/cli-cm-import': ~1.9.2 '@contentstack/cli-cm-migrate-rte': ~1.4.12 '@contentstack/cli-cm-seed': ~1.5.1 '@contentstack/cli-command': ~1.2.13 From 3488aeda4b662fa7fad9c915e9ae1d1a289eeec5 Mon Sep 17 00:00:00 2001 From: Vikram Kalta Date: Wed, 18 Oct 2023 11:47:26 +0100 Subject: [PATCH 04/41] fix: minor fix --- .../src/import/module-importer.ts | 28 ++++++++++--------- 1 file changed, 15 insertions(+), 13 deletions(-) diff --git a/packages/contentstack-import/src/import/module-importer.ts b/packages/contentstack-import/src/import/module-importer.ts index e89ea9948e..f6270792d9 100755 --- a/packages/contentstack-import/src/import/module-importer.ts +++ b/packages/contentstack-import/src/import/module-importer.ts @@ -26,19 +26,21 @@ class ModuleImporter { // Temporarily adding this api call to verify management token has read and write permissions // TODO: CS-40354 - CLI | import rewrite | Migrate HTTP call to SDK call once fix is ready from SDK side - const httpClient = new HttpClient({ - headers: { api_key: this.importConfig.apiKey, authorization: this.importConfig.management_token }, - }); - - const { data } = await httpClient.post(`https://${this.importConfig.host}/v3/locales`, { - locale: { - name: 'English', - code: 'en-us', - }, - }); - - if ([161, 105].includes(data.error_code)) { - throw new Error(data.error_code === 105 ? 'Sorry but you don\'t have access to this stack' : data.error_message); + if (this.importConfig.management_token) { + const httpClient = new HttpClient({ + headers: { api_key: this.importConfig.apiKey, authorization: this.importConfig.management_token }, + }); + + const { data } = await httpClient.post(`https://${this.importConfig.host}/v3/locales`, { + locale: { + name: 'English', + code: 'en-us', + }, + }); + + if ([161, 105].includes(data.error_code)) { + throw new Error(data.error_code === 105 ? 'Sorry but you don\'t have access to this stack' : data.error_message); + } } if (!this.importConfig.master_locale) { From 0583ad86e8a5cfb82170e1216d95ba2a281c808f Mon Sep 17 00:00:00 2001 From: shafeeqd959 Date: Tue, 31 Oct 2023 16:56:32 +0530 Subject: [PATCH 05/41] added asset overwrite, enabled entries, removed module dependency with overwrite --- package-lock.json | 2 + packages/contentstack-audit/README.md | 2 +- packages/contentstack-auth/README.md | 2 +- packages/contentstack-bootstrap/README.md | 2 +- packages/contentstack-branches/README.md | 2 +- packages/contentstack-bulk-publish/README.md | 2 +- packages/contentstack-clone/README.md | 2 +- packages/contentstack-config/README.md | 2 +- packages/contentstack-export/README.md | 2 +- packages/contentstack-import/README.md | 2 +- packages/contentstack-import/package.json | 7 ++-- .../src/commands/cm/stacks/import.ts | 1 - .../contentstack-import/src/config/index.ts | 1 - .../src/import/modules/assets.ts | 40 ++++++++++++++++--- .../src/import/modules/entries.ts | 7 +--- .../src/types/default-config.ts | 1 - .../src/utils/common-helper.ts | 16 ++++++++ .../src/utils/import-config-handler.ts | 10 ----- packages/contentstack-launch/README.md | 2 +- packages/contentstack-migrate-rte/README.md | 2 +- packages/contentstack-migration/README.md | 2 +- packages/contentstack/README.md | 16 ++++---- pnpm-lock.yaml | 2 + 23 files changed, 81 insertions(+), 46 deletions(-) diff --git a/package-lock.json b/package-lock.json index 9cbe4c49b4..0639473c0c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -24540,6 +24540,7 @@ "mkdirp": "^1.0.4", "promise-limit": "^2.7.0", "tslib": "^2.4.1", + "uuid": "^9.0.0", "winston": "^3.7.2" }, "devDependencies": { @@ -28011,6 +28012,7 @@ "ts-node": "^10.9.1", "tslib": "^2.4.1", "typescript": "^4.9.3", + "uuid": "^9.0.0", "winston": "^3.7.2" }, "dependencies": { diff --git a/packages/contentstack-audit/README.md b/packages/contentstack-audit/README.md index 0b662fc7e2..aab6df95b9 100644 --- a/packages/contentstack-audit/README.md +++ b/packages/contentstack-audit/README.md @@ -19,7 +19,7 @@ $ npm install -g @contentstack/cli-audit $ csdx COMMAND running command... $ csdx (--version|-v) -@contentstack/cli-audit/1.2.0 darwin-arm64 node-v20.8.0 +@contentstack/cli-audit/1.2.0 darwin-arm64 node-v18.11.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-auth/README.md b/packages/contentstack-auth/README.md index 1a65450ec5..c62236dc78 100644 --- a/packages/contentstack-auth/README.md +++ b/packages/contentstack-auth/README.md @@ -18,7 +18,7 @@ $ npm install -g @contentstack/cli-auth $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-auth/1.3.15 darwin-arm64 node-v20.8.0 +@contentstack/cli-auth/1.3.15 darwin-arm64 node-v18.11.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-bootstrap/README.md b/packages/contentstack-bootstrap/README.md index dff552cae8..d419b51e39 100644 --- a/packages/contentstack-bootstrap/README.md +++ b/packages/contentstack-bootstrap/README.md @@ -15,7 +15,7 @@ $ npm install -g @contentstack/cli-cm-bootstrap $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-cm-bootstrap/1.6.0 darwin-arm64 node-v20.8.0 +@contentstack/cli-cm-bootstrap/1.6.0 darwin-arm64 node-v18.11.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-branches/README.md b/packages/contentstack-branches/README.md index 9587da605b..616c388c76 100755 --- a/packages/contentstack-branches/README.md +++ b/packages/contentstack-branches/README.md @@ -37,7 +37,7 @@ $ npm install -g @contentstack/cli-cm-branches $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-cm-branches/1.0.15 darwin-arm64 node-v20.8.0 +@contentstack/cli-cm-branches/1.0.15 darwin-arm64 node-v18.11.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-bulk-publish/README.md b/packages/contentstack-bulk-publish/README.md index 203ca12d63..0326c48798 100644 --- a/packages/contentstack-bulk-publish/README.md +++ b/packages/contentstack-bulk-publish/README.md @@ -18,7 +18,7 @@ $ npm install -g @contentstack/cli-cm-bulk-publish $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-cm-bulk-publish/1.3.13 darwin-arm64 node-v20.8.0 +@contentstack/cli-cm-bulk-publish/1.3.13 darwin-arm64 node-v18.11.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-clone/README.md b/packages/contentstack-clone/README.md index 648300f4db..f7028b4dc1 100644 --- a/packages/contentstack-clone/README.md +++ b/packages/contentstack-clone/README.md @@ -16,7 +16,7 @@ $ npm install -g @contentstack/cli-cm-clone $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-cm-clone/1.6.0 darwin-arm64 node-v20.8.0 +@contentstack/cli-cm-clone/1.6.0 darwin-arm64 node-v18.11.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-config/README.md b/packages/contentstack-config/README.md index f47f435180..4edacb273f 100644 --- a/packages/contentstack-config/README.md +++ b/packages/contentstack-config/README.md @@ -18,7 +18,7 @@ $ npm install -g @contentstack/cli-config $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-config/1.4.13 darwin-arm64 node-v20.8.0 +@contentstack/cli-config/1.4.13 darwin-arm64 node-v18.11.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-export/README.md b/packages/contentstack-export/README.md index c36ef67f18..5fcc1c51cc 100755 --- a/packages/contentstack-export/README.md +++ b/packages/contentstack-export/README.md @@ -48,7 +48,7 @@ $ npm install -g @contentstack/cli-cm-export $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-cm-export/1.9.2 darwin-arm64 node-v20.8.0 +@contentstack/cli-cm-export/1.9.2 darwin-arm64 node-v18.11.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-import/README.md b/packages/contentstack-import/README.md index d8d1ef8968..9af92f71dc 100644 --- a/packages/contentstack-import/README.md +++ b/packages/contentstack-import/README.md @@ -47,7 +47,7 @@ $ npm install -g @contentstack/cli-cm-import $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-cm-import/1.10.0 darwin-arm64 node-v20.8.0 +@contentstack/cli-cm-import/1.10.0 darwin-arm64 node-v18.11.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-import/package.json b/packages/contentstack-import/package.json index 6536e29eb8..2a5295944f 100644 --- a/packages/contentstack-import/package.json +++ b/packages/contentstack-import/package.json @@ -1,7 +1,7 @@ { "name": "@contentstack/cli-cm-import", "description": "Contentstack CLI plugin to import content into stack", - "version": "1.10.0", + "version": "1.10.1", "author": "Contentstack", "bugs": "https://github.com/contentstack/cli/issues", "dependencies": { @@ -21,7 +21,8 @@ "mkdirp": "^1.0.4", "promise-limit": "^2.7.0", "tslib": "^2.4.1", - "winston": "^3.7.2" + "winston": "^3.7.2", + "uuid": "^9.0.0" }, "devDependencies": { "@oclif/test": "^1.2.6", @@ -97,4 +98,4 @@ } }, "repository": "https://github.com/contentstack/cli" -} +} \ No newline at end of file diff --git a/packages/contentstack-import/src/commands/cm/stacks/import.ts b/packages/contentstack-import/src/commands/cm/stacks/import.ts index 45bf0ccc3a..aa183229bc 100644 --- a/packages/contentstack-import/src/commands/cm/stacks/import.ts +++ b/packages/contentstack-import/src/commands/cm/stacks/import.ts @@ -97,7 +97,6 @@ export default class ImportCommand extends Command { 'replace-existing': flags.boolean({ required: false, description: 'Replaces the existing module in the target stack.', - dependsOn: ['module'], }), 'skip-existing': flags.boolean({ required: false, diff --git a/packages/contentstack-import/src/config/index.ts b/packages/contentstack-import/src/config/index.ts index 4f472a5bb6..c9003f3622 100644 --- a/packages/contentstack-import/src/config/index.ts +++ b/packages/contentstack-import/src/config/index.ts @@ -367,7 +367,6 @@ const config: DefaultConfig = { stacks: '/stacks/', labels: '/labels/', }, - overwriteSupportedModules: ['extensions', 'global-fields', 'content-types'], rateLimit: 5, preserveStackVersion: false, entriesPublish: true, diff --git a/packages/contentstack-import/src/import/modules/assets.ts b/packages/contentstack-import/src/import/modules/assets.ts index 8b048da5bf..5baca94554 100644 --- a/packages/contentstack-import/src/import/modules/assets.ts +++ b/packages/contentstack-import/src/import/modules/assets.ts @@ -7,11 +7,12 @@ import isEmpty from 'lodash/isEmpty'; import uniq from 'lodash/uniq'; import { existsSync } from 'node:fs'; import includes from 'lodash/includes'; +import { v4 as uuid } from 'uuid'; import { resolve as pResolve, join } from 'node:path'; import { FsUtility } from '@contentstack/cli-utilities'; import config from '../../config'; -import { log, formatError } from '../../utils'; +import { log, formatError, formatDate } from '../../utils'; import BaseClass, { ApiOptions } from './base-class'; import { ModuleClassParams } from '../../types'; @@ -28,6 +29,7 @@ export default class ImportAssets extends BaseClass { private assetsUidMap: Record = {}; private assetsUrlMap: Record = {}; private assetsFolderMap: Record = {}; + private rootFolder: { uid: any; name: any; parent_uid: unknown; created_at: any }; constructor({ importConfig, stackAPIClient }: ModuleClassParams) { super({ importConfig, stackAPIClient }); @@ -227,6 +229,9 @@ export default class ImportAssets extends BaseClass { if (asset.parent_uid) { asset.parent_uid = this.assetsFolderMap[asset.parent_uid]; + } else if (this.importConfig.replaceExisting) { + // adds the root folder as parent for all assets in the root level + asset.parent_uid = this.assetsFolderMap[this.rootFolder.uid]; } apiOptions.apiData = asset; @@ -304,16 +309,17 @@ export default class ImportAssets extends BaseClass { * @returns {Array>} Array> */ constructFolderImportOrder(folders: any): Array> { - let parentUid: unknown[] = []; + let parentUIds: unknown[] = []; + // NOTE: Read root folder const importOrder = filter(folders, { parent_uid: null }).map(({ uid, name, parent_uid, created_at }) => { - parentUid.push(uid); + parentUIds.push(uid); return { uid, name, parent_uid, created_at }; }); - while (!isEmpty(parentUid)) { + while (!isEmpty(parentUIds)) { // NOTE: Read nested folders every iteration until we find empty folders - parentUid = filter(folders, ({ parent_uid }) => includes(parentUid, parent_uid)).map( + parentUIds = filter(folders, ({ parent_uid }) => includes(parentUIds, parent_uid)).map( ({ uid, name, parent_uid, created_at }) => { importOrder.push({ uid, name, parent_uid, created_at }); return uid; @@ -321,6 +327,30 @@ export default class ImportAssets extends BaseClass { ); } + if (this.importConfig.replaceExisting) { + // Note: adds a root folder to distinguish latest asset uploads + // Todo: This temporary approach should be updated with asset and folder overwrite strategy, which follows + // folder overwrite + // 1. Create folder trees, 2. Export all target stack folders, 3.Match the source to target folders and create a list of existing folders + // 4. Replace existing folders + // Asset overwrite + // 1. Search asset with title + filename + type + // 2. if there are multiple assets fetched with same query, then check the parent uid against mapper created while importing folders + // 3. Replace matched assets + this.rootFolder = { + uid: uuid(), + name: `Assets-${formatDate()}`, + parent_uid: null, + created_at: null, + }; + filter(importOrder, (folder, index) => { + if (!folder.parent_uid) { + importOrder.splice(index, 1, { ...folder, parent_uid: this.rootFolder.uid }); + } + }); + // NOTE: Adds root folder + importOrder.unshift(this.rootFolder); + } return importOrder; } } diff --git a/packages/contentstack-import/src/import/modules/entries.ts b/packages/contentstack-import/src/import/modules/entries.ts index 75c77da1c4..d8059dc8c4 100644 --- a/packages/contentstack-import/src/import/modules/entries.ts +++ b/packages/contentstack-import/src/import/modules/entries.ts @@ -107,7 +107,7 @@ export default class EntriesImport extends BaseClass { for (let entryRequestOption of entryRequestOptions) { await this.createEntries(entryRequestOption); } - if (this.importConfig.replaceExisting && indexOf(this.importConfig.overwriteSupportedModules, 'entries') !== -1) { + if (this.importConfig.replaceExisting) { // Note: Instead of using entryRequestOptions, we can prepare request options for replace, to avoid unnecessary operations for (let entryRequestOption of entryRequestOptions) { await this.replaceEntries(entryRequestOption).catch((error) => { @@ -336,10 +336,7 @@ export default class EntriesImport extends BaseClass { //Note: write existing entries into files to handler later if (error.errorCode === 119) { if (error?.errors?.title || error?.errors?.uid) { - if ( - this.importConfig.replaceExisting && - indexOf(this.importConfig.overwriteSupportedModules, 'entries') !== -1 - ) { + if (this.importConfig.replaceExisting) { entry.entryOldUid = uid; entry.sourceEntryFilePath = path.join(basePath, additionalInfo.entryFileName); // stores source file path temporarily existingEntriesFileHelper.writeIntoFile({ [uid]: entry } as any, { mapKeyVal: true }); diff --git a/packages/contentstack-import/src/types/default-config.ts b/packages/contentstack-import/src/types/default-config.ts index 7e4dfd1067..c41b949fdb 100644 --- a/packages/contentstack-import/src/types/default-config.ts +++ b/packages/contentstack-import/src/types/default-config.ts @@ -140,5 +140,4 @@ export default interface DefaultConfig { marketplaceAppEncryptionKey: string; getEncryptionKeyMaxRetry: number; createBackupDir?: string; - overwriteSupportedModules: string[]; } diff --git a/packages/contentstack-import/src/utils/common-helper.ts b/packages/contentstack-import/src/utils/common-helper.ts index 1d171e06fa..ad8a471f52 100644 --- a/packages/contentstack-import/src/utils/common-helper.ts +++ b/packages/contentstack-import/src/utils/common-helper.ts @@ -233,3 +233,19 @@ export const validateBranch = async (stackAPIClient: any, config: ImportConfig, } }); }; + +export const formatDate = (date: Date = new Date()) => { + // Format the date manually + const formattedDate = `${date.getFullYear()}-${(date.getMonth() + 1).toString().padStart(2, '0')}-${date + .getDate() + .toString() + .padStart(2, '0')}T${date.getHours().toString().padStart(2, '0')}-${date + .getMinutes() + .toString() + .padStart(2, '0')}-${date.getSeconds().toString().padStart(2, '0')}-${date + .getMilliseconds() + .toString() + .padStart(3, '0')}Z`; + + return formattedDate; +}; diff --git a/packages/contentstack-import/src/utils/import-config-handler.ts b/packages/contentstack-import/src/utils/import-config-handler.ts index 7aaba9a457..111df826fb 100644 --- a/packages/contentstack-import/src/utils/import-config-handler.ts +++ b/packages/contentstack-import/src/utils/import-config-handler.ts @@ -86,16 +86,6 @@ const setupConfig = async (importCmdFlags: any): Promise => { config.replaceExisting = importCmdFlags['replace-existing']; config.skipExisting = importCmdFlags['skip-existing']; - if (config.replaceExisting && !includes(config.overwriteSupportedModules, config.moduleName)) { - throw new Error( - `Failed to overwrite ${ - config.moduleName - } module! Currently, with the import command, you can overwrite the following modules: ${config.overwriteSupportedModules.join( - ',', - )}`, - ); - } - return config; }; diff --git a/packages/contentstack-launch/README.md b/packages/contentstack-launch/README.md index d939bda965..7b101d9976 100755 --- a/packages/contentstack-launch/README.md +++ b/packages/contentstack-launch/README.md @@ -19,7 +19,7 @@ $ npm install -g @contentstack/cli-launch $ csdx COMMAND running command... $ csdx (--version|-v) -@contentstack/cli-launch/1.0.13 darwin-arm64 node-v20.8.0 +@contentstack/cli-launch/1.0.13 darwin-arm64 node-v18.11.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-migrate-rte/README.md b/packages/contentstack-migrate-rte/README.md index 7cb9201ea9..11d5163944 100644 --- a/packages/contentstack-migrate-rte/README.md +++ b/packages/contentstack-migrate-rte/README.md @@ -16,7 +16,7 @@ $ npm install -g @contentstack/cli-cm-migrate-rte $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-cm-migrate-rte/1.4.13 darwin-arm64 node-v20.8.0 +@contentstack/cli-cm-migrate-rte/1.4.13 darwin-arm64 node-v18.11.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-migration/README.md b/packages/contentstack-migration/README.md index fbed0cb23b..5ea10489e7 100644 --- a/packages/contentstack-migration/README.md +++ b/packages/contentstack-migration/README.md @@ -21,7 +21,7 @@ $ npm install -g @contentstack/cli-migration $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-migration/1.3.14 darwin-arm64 node-v20.8.0 +@contentstack/cli-migration/1.3.14 darwin-arm64 node-v18.11.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack/README.md b/packages/contentstack/README.md index 1cabac530d..82a67213bf 100644 --- a/packages/contentstack/README.md +++ b/packages/contentstack/README.md @@ -18,7 +18,7 @@ $ npm install -g @contentstack/cli $ csdx COMMAND running command... $ csdx (--version|-v) -@contentstack/cli/1.10.0 darwin-arm64 node-v20.8.0 +@contentstack/cli/1.10.0 darwin-arm64 node-v18.11.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND @@ -2987,7 +2987,7 @@ DESCRIPTION Display help for csdx. ``` -_See code: [@oclif/plugin-help](https://github.com/oclif/plugin-help/blob/v5.2.14/src/commands/help.ts)_ +_See code: [@oclif/plugin-help](https://github.com/oclif/plugin-help/blob/v5.2.20/src/commands/help.ts)_ ## `csdx launch` @@ -3285,7 +3285,7 @@ EXAMPLES $ csdx plugins ``` -_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.3.2/src/commands/plugins/index.ts)_ +_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.8.4/src/commands/plugins/index.ts)_ ## `csdx plugins:install PLUGIN...` @@ -3350,7 +3350,7 @@ EXAMPLES $ csdx plugins:inspect myplugin ``` -_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.3.2/src/commands/plugins/inspect.ts)_ +_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.8.4/src/commands/plugins/inspect.ts)_ ## `csdx plugins:install PLUGIN...` @@ -3390,7 +3390,7 @@ EXAMPLES $ csdx plugins:install someuser/someplugin ``` -_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.3.2/src/commands/plugins/install.ts)_ +_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.8.4/src/commands/plugins/install.ts)_ ## `csdx plugins:link PLUGIN` @@ -3419,7 +3419,7 @@ EXAMPLES $ csdx plugins:link myplugin ``` -_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.3.2/src/commands/plugins/link.ts)_ +_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.8.4/src/commands/plugins/link.ts)_ ## `csdx plugins:uninstall PLUGIN...` @@ -3467,7 +3467,7 @@ ALIASES $ csdx plugins:remove ``` -_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.3.2/src/commands/plugins/uninstall.ts)_ +_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.8.4/src/commands/plugins/uninstall.ts)_ ## `csdx plugins:uninstall PLUGIN...` @@ -3508,7 +3508,7 @@ DESCRIPTION Update installed plugins. ``` -_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.3.2/src/commands/plugins/update.ts)_ +_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.8.4/src/commands/plugins/update.ts)_ ## `csdx tokens` diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 99e6a0743e..f313c92e47 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -749,6 +749,7 @@ importers: ts-node: ^10.9.1 tslib: ^2.4.1 typescript: ^4.9.3 + uuid: ^9.0.0 winston: ^3.7.2 dependencies: '@contentstack/cli-command': link:../contentstack-command @@ -767,6 +768,7 @@ importers: mkdirp: 1.0.4 promise-limit: 2.7.0 tslib: 2.6.0 + uuid: 9.0.1 winston: 3.10.0 devDependencies: '@oclif/test': 1.2.9 From 78988dc628dc8fba62e475f8a488dca4580a01b4 Mon Sep 17 00:00:00 2001 From: Aman Kumar Date: Tue, 31 Oct 2023 17:44:01 +0530 Subject: [PATCH 06/41] fix: incorrect date format in merge script --- .../src/utils/create-merge-scripts.ts | 6 ++---- packages/contentstack-utilities/src/date-time.ts | 15 +++++++++++++++ packages/contentstack-utilities/src/index.ts | 1 + 3 files changed, 18 insertions(+), 4 deletions(-) create mode 100644 packages/contentstack-utilities/src/date-time.ts diff --git a/packages/contentstack-branches/src/utils/create-merge-scripts.ts b/packages/contentstack-branches/src/utils/create-merge-scripts.ts index 9112abe615..239cb86a27 100644 --- a/packages/contentstack-branches/src/utils/create-merge-scripts.ts +++ b/packages/contentstack-branches/src/utils/create-merge-scripts.ts @@ -1,5 +1,5 @@ import fs from 'fs'; -import { cliux } from '@contentstack/cli-utilities'; +import { cliux, formatTime, formatDate } from '@contentstack/cli-utilities'; import { entryCreateScript } from './entry-create-script'; import { entryUpdateScript } from './entry-update-script'; import { entryCreateUpdateScript } from './entry-create-update-script'; @@ -74,9 +74,7 @@ export function getContentTypeMergeStatus(status) { export function createMergeScripts(contentType: CreateMergeScriptsProps, mergeJobUID: string, content?: any) { const date = new Date(); const rootFolder = 'merge_scripts'; - const fileCreatedAt = `${date.getFullYear()}${ - date.getMonth().toString.length === 1 ? `0${date.getMonth() + 1}` : date.getMonth() + 1 - }${date.getUTCDate()}${date.getHours()}${date.getMinutes()}${date.getSeconds()}`; + const fileCreatedAt = `${formatDate(date)}${formatTime(date)}`; const mergeScriptsSlug = `merge_scripts_${mergeJobUID}_${fileCreatedAt}`; const fullPath = `${rootFolder}/${mergeScriptsSlug}`; diff --git a/packages/contentstack-utilities/src/date-time.ts b/packages/contentstack-utilities/src/date-time.ts new file mode 100644 index 0000000000..22e38e95fd --- /dev/null +++ b/packages/contentstack-utilities/src/date-time.ts @@ -0,0 +1,15 @@ +export const formatDate = (date: Date) => { + return [ + date.getFullYear(), + (date.getMonth() + 1).toString().padStart(2, '0'), + date.getDate().toString().padStart(2, '0'), + ].join(''); +}; + +export const formatTime = (date: Date) => { + return [ + date.getHours().toString().padStart(2, '0'), + date.getMinutes().toString().padStart(2, '0'), + date.getSeconds().toString().padStart(2, '0'), + ].join(''); +}; diff --git a/packages/contentstack-utilities/src/index.ts b/packages/contentstack-utilities/src/index.ts index 573e7570f3..0a9d76f8dc 100644 --- a/packages/contentstack-utilities/src/index.ts +++ b/packages/contentstack-utilities/src/index.ts @@ -18,6 +18,7 @@ export { default as NodeCrypto } from './encrypter'; export { Args as args, Flags as flags, Command } from './cli-ux'; export * from './helpers'; export * from './interfaces'; +export * from './date-time'; // NOTE Exporting all @oclif/core modules: So that all the module can be acessed through cli-utility export { From 6e6ea3e2aaea5d68cfb7a3ac38851d60749f7905 Mon Sep 17 00:00:00 2001 From: shafeeqd959 Date: Tue, 31 Oct 2023 18:17:25 +0530 Subject: [PATCH 07/41] bumped versions --- package-lock.json | 281 ++++++++++++++++++- packages/contentstack-audit/README.md | 2 +- packages/contentstack-auth/README.md | 2 +- packages/contentstack-bootstrap/README.md | 2 +- packages/contentstack-bootstrap/package.json | 4 +- packages/contentstack-branches/README.md | 2 +- packages/contentstack-bulk-publish/README.md | 2 +- packages/contentstack-clone/README.md | 2 +- packages/contentstack-clone/package.json | 4 +- packages/contentstack-config/README.md | 2 +- packages/contentstack-export/README.md | 2 +- packages/contentstack-import/README.md | 2 +- packages/contentstack-import/package.json | 2 +- packages/contentstack-launch/README.md | 2 +- packages/contentstack-migrate-rte/README.md | 2 +- packages/contentstack-migration/README.md | 2 +- packages/contentstack-seed/package.json | 6 +- packages/contentstack/README.md | 16 +- packages/contentstack/package.json | 4 +- pnpm-lock.yaml | 200 ++++++++++++- 20 files changed, 491 insertions(+), 50 deletions(-) diff --git a/package-lock.json b/package-lock.json index 0639473c0c..5d2171e4bc 100644 --- a/package-lock.json +++ b/package-lock.json @@ -22835,7 +22835,7 @@ }, "packages/contentstack": { "name": "@contentstack/cli", - "version": "1.10.0", + "version": "1.11.0", "license": "MIT", "dependencies": { "@contentstack/cli-audit": "~1.2.0", @@ -22846,7 +22846,7 @@ "@contentstack/cli-cm-clone": "~1.6.0", "@contentstack/cli-cm-export": "~1.9.2", "@contentstack/cli-cm-export-to-csv": "~1.4.4", - "@contentstack/cli-cm-import": "~1.10.0", + "@contentstack/cli-cm-import": "~1.11.0", "@contentstack/cli-cm-migrate-rte": "~1.4.13", "@contentstack/cli-cm-seed": "~1.6.0", "@contentstack/cli-command": "~1.2.14", @@ -23593,10 +23593,10 @@ }, "packages/contentstack-bootstrap": { "name": "@contentstack/cli-cm-bootstrap", - "version": "1.6.0", + "version": "1.7.0", "license": "MIT", "dependencies": { - "@contentstack/cli-cm-seed": "~1.6.0", + "@contentstack/cli-cm-seed": "~1.7.0", "@contentstack/cli-command": "~1.2.14", "@contentstack/cli-utilities": "~1.5.4", "inquirer": "8.2.4", @@ -23782,12 +23782,12 @@ }, "packages/contentstack-clone": { "name": "@contentstack/cli-cm-clone", - "version": "1.6.0", + "version": "1.7.0", "license": "MIT", "dependencies": { "@colors/colors": "^1.5.0", "@contentstack/cli-cm-export": "~1.9.0", - "@contentstack/cli-cm-import": "~1.10.0", + "@contentstack/cli-cm-import": "~1.11.0", "@contentstack/cli-command": "~1.2.14", "@contentstack/cli-utilities": "~1.5.4", "async": "^3.2.4", @@ -24521,7 +24521,7 @@ }, "packages/contentstack-import": { "name": "@contentstack/cli-cm-import", - "version": "1.10.0", + "version": "1.11.0", "license": "MIT", "dependencies": { "@contentstack/cli-command": "~1.2.14", @@ -25218,10 +25218,10 @@ }, "packages/contentstack-seed": { "name": "@contentstack/cli-cm-seed", - "version": "1.6.1", + "version": "1.7.0", "license": "MIT", "dependencies": { - "@contentstack/cli-cm-import": "~1.10.0", + "@contentstack/cli-cm-import": "~1.11.0", "@contentstack/cli-command": "~1.2.14", "@contentstack/cli-utilities": "~1.5.4", "inquirer": "8.2.4", @@ -26387,6 +26387,141 @@ "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", "dev": true + }, + "packages/contentstack/node_modules/@contentstack/cli-cm-bootstrap": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@contentstack/cli-cm-bootstrap/-/cli-cm-bootstrap-1.6.0.tgz", + "integrity": "sha512-X1UB4lotUwCYs/Lyc4kXTwVZDF5n0iwNP3l31ej74j8md6esVlAO89uOio93NE2hEcEMUBui7Qcx+KnUz9kf/A==", + "dependencies": { + "@contentstack/cli-cm-seed": "~1.6.0", + "@contentstack/cli-command": "~1.2.14", + "@contentstack/cli-utilities": "~1.5.4", + "inquirer": "8.2.4", + "mkdirp": "^1.0.4", + "tar": "^6.1.13" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "packages/contentstack/node_modules/@contentstack/cli-cm-clone": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@contentstack/cli-cm-clone/-/cli-cm-clone-1.6.0.tgz", + "integrity": "sha512-b/NxS1PhMa0RlGxjrRaeggqVNttrkhC3ptLbXjh+Cdfmonrdei9x2/4OkA6Q0McIVlsGPLb4RaoUr+cm5+ZyKA==", + "dependencies": { + "@colors/colors": "^1.5.0", + "@contentstack/cli-cm-export": "~1.9.0", + "@contentstack/cli-cm-import": "~1.10.0", + "@contentstack/cli-command": "~1.2.14", + "@contentstack/cli-utilities": "~1.5.4", + "async": "^3.2.4", + "chalk": "^4.1.0", + "child_process": "^1.0.2", + "fancy-test": "^1.4.10", + "inquirer": "8.2.4", + "ora": "^5.1.0", + "prompt": "^1.3.0", + "rimraf": "^3.0.2", + "winston": "^3.7.2" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "packages/contentstack/node_modules/@contentstack/cli-cm-clone/node_modules/@contentstack/cli-cm-import": { + "version": "1.10.0", + "resolved": "https://registry.npmjs.org/@contentstack/cli-cm-import/-/cli-cm-import-1.10.0.tgz", + "integrity": "sha512-Jn9grDE2J1c4iGBcPv24Q8lj/ozgfD9QNbJcn+1a6oGjA6OE+a39agQwi04nByBw4xRtbLUmHa4nfFRaF7qkvQ==", + "dependencies": { + "@contentstack/cli-command": "~1.2.14", + "@contentstack/cli-utilities": "~1.5.4", + "@contentstack/management": "~1.10.2", + "@oclif/core": "^2.9.3", + "big-json": "^3.2.0", + "bluebird": "^3.7.2", + "chalk": "^4.1.2", + "debug": "^4.1.0", + "fs-extra": "^11.1.1", + "lodash": "^4.17.20", + "marked": "^4.0.17", + "merge": "^2.1.1", + "mkdirp": "^1.0.4", + "promise-limit": "^2.7.0", + "tslib": "^2.4.1", + "winston": "^3.7.2" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "packages/contentstack/node_modules/@contentstack/cli-cm-clone/node_modules/rimraf": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", + "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==", + "dependencies": { + "glob": "^7.1.3" + }, + "bin": { + "rimraf": "bin.js" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "packages/contentstack/node_modules/@contentstack/cli-cm-seed": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@contentstack/cli-cm-seed/-/cli-cm-seed-1.6.0.tgz", + "integrity": "sha512-aAhi3iuwbo/bv/j0RWS+OesdTqrQkEsIwVfxVOSUCDUrvJ29O7289pb07L0bO3THkTCz0d5bTT+oj5KK68ZWuA==", + "dependencies": { + "@contentstack/cli-cm-import": "~1.10.0", + "@contentstack/cli-command": "~1.2.14", + "@contentstack/cli-utilities": "~1.5.4", + "axios": "1.3.4", + "inquirer": "8.2.4", + "mkdirp": "^1.0.4", + "tar": "^6.1.13", + "tmp": "^0.2.1", + "tslib": "^2.4.1" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "packages/contentstack/node_modules/@contentstack/cli-cm-seed/node_modules/@contentstack/cli-cm-import": { + "version": "1.10.0", + "resolved": "https://registry.npmjs.org/@contentstack/cli-cm-import/-/cli-cm-import-1.10.0.tgz", + "integrity": "sha512-Jn9grDE2J1c4iGBcPv24Q8lj/ozgfD9QNbJcn+1a6oGjA6OE+a39agQwi04nByBw4xRtbLUmHa4nfFRaF7qkvQ==", + "dependencies": { + "@contentstack/cli-command": "~1.2.14", + "@contentstack/cli-utilities": "~1.5.4", + "@contentstack/management": "~1.10.2", + "@oclif/core": "^2.9.3", + "big-json": "^3.2.0", + "bluebird": "^3.7.2", + "chalk": "^4.1.2", + "debug": "^4.1.0", + "fs-extra": "^11.1.1", + "lodash": "^4.17.20", + "marked": "^4.0.17", + "merge": "^2.1.1", + "mkdirp": "^1.0.4", + "promise-limit": "^2.7.0", + "tslib": "^2.4.1", + "winston": "^3.7.2" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "packages/contentstack/node_modules/axios": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.3.4.tgz", + "integrity": "sha512-toYm+Bsyl6VC5wSkfkbbNB6ROv7KY93PEBBL6xyDczaIHasAiv4wPqQ/c4RjoQzipxRD2W5g21cOqQulZ7rHwQ==", + "dependencies": { + "follow-redirects": "^1.15.0", + "form-data": "^4.0.0", + "proxy-from-env": "^1.1.0" + } } }, "dependencies": { @@ -26969,7 +27104,7 @@ "@contentstack/cli-cm-clone": "~1.6.0", "@contentstack/cli-cm-export": "~1.9.2", "@contentstack/cli-cm-export-to-csv": "~1.4.4", - "@contentstack/cli-cm-import": "~1.10.0", + "@contentstack/cli-cm-import": "~1.11.0", "@contentstack/cli-cm-migrate-rte": "~1.4.13", "@contentstack/cli-cm-seed": "~1.6.0", "@contentstack/cli-command": "~1.2.14", @@ -27014,6 +27149,126 @@ "typescript": "^4.9.3", "uuid": "^9.0.0", "winston": "^3.7.2" + }, + "dependencies": { + "@contentstack/cli-cm-bootstrap": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@contentstack/cli-cm-bootstrap/-/cli-cm-bootstrap-1.6.0.tgz", + "integrity": "sha512-X1UB4lotUwCYs/Lyc4kXTwVZDF5n0iwNP3l31ej74j8md6esVlAO89uOio93NE2hEcEMUBui7Qcx+KnUz9kf/A==", + "requires": { + "@contentstack/cli-cm-seed": "~1.6.0", + "@contentstack/cli-command": "~1.2.14", + "@contentstack/cli-utilities": "~1.5.4", + "inquirer": "8.2.4", + "mkdirp": "^1.0.4", + "tar": "^6.1.13" + } + }, + "@contentstack/cli-cm-clone": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@contentstack/cli-cm-clone/-/cli-cm-clone-1.6.0.tgz", + "integrity": "sha512-b/NxS1PhMa0RlGxjrRaeggqVNttrkhC3ptLbXjh+Cdfmonrdei9x2/4OkA6Q0McIVlsGPLb4RaoUr+cm5+ZyKA==", + "requires": { + "@colors/colors": "^1.5.0", + "@contentstack/cli-cm-export": "~1.9.0", + "@contentstack/cli-cm-import": "~1.10.0", + "@contentstack/cli-command": "~1.2.14", + "@contentstack/cli-utilities": "~1.5.4", + "async": "^3.2.4", + "chalk": "^4.1.0", + "child_process": "^1.0.2", + "fancy-test": "^1.4.10", + "inquirer": "8.2.4", + "ora": "^5.1.0", + "prompt": "^1.3.0", + "rimraf": "^3.0.2", + "winston": "^3.7.2" + }, + "dependencies": { + "@contentstack/cli-cm-import": { + "version": "1.10.0", + "resolved": "https://registry.npmjs.org/@contentstack/cli-cm-import/-/cli-cm-import-1.10.0.tgz", + "integrity": "sha512-Jn9grDE2J1c4iGBcPv24Q8lj/ozgfD9QNbJcn+1a6oGjA6OE+a39agQwi04nByBw4xRtbLUmHa4nfFRaF7qkvQ==", + "requires": { + "@contentstack/cli-command": "~1.2.14", + "@contentstack/cli-utilities": "~1.5.4", + "@contentstack/management": "~1.10.2", + "@oclif/core": "^2.9.3", + "big-json": "^3.2.0", + "bluebird": "^3.7.2", + "chalk": "^4.1.2", + "debug": "^4.1.0", + "fs-extra": "^11.1.1", + "lodash": "^4.17.20", + "marked": "^4.0.17", + "merge": "^2.1.1", + "mkdirp": "^1.0.4", + "promise-limit": "^2.7.0", + "tslib": "^2.4.1", + "winston": "^3.7.2" + } + }, + "rimraf": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", + "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==", + "requires": { + "glob": "^7.1.3" + } + } + } + }, + "@contentstack/cli-cm-seed": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@contentstack/cli-cm-seed/-/cli-cm-seed-1.6.0.tgz", + "integrity": "sha512-aAhi3iuwbo/bv/j0RWS+OesdTqrQkEsIwVfxVOSUCDUrvJ29O7289pb07L0bO3THkTCz0d5bTT+oj5KK68ZWuA==", + "requires": { + "@contentstack/cli-cm-import": "~1.10.0", + "@contentstack/cli-command": "~1.2.14", + "@contentstack/cli-utilities": "~1.5.4", + "axios": "1.3.4", + "inquirer": "8.2.4", + "mkdirp": "^1.0.4", + "tar": "^6.1.13", + "tmp": "^0.2.1", + "tslib": "^2.4.1" + }, + "dependencies": { + "@contentstack/cli-cm-import": { + "version": "1.10.0", + "resolved": "https://registry.npmjs.org/@contentstack/cli-cm-import/-/cli-cm-import-1.10.0.tgz", + "integrity": "sha512-Jn9grDE2J1c4iGBcPv24Q8lj/ozgfD9QNbJcn+1a6oGjA6OE+a39agQwi04nByBw4xRtbLUmHa4nfFRaF7qkvQ==", + "requires": { + "@contentstack/cli-command": "~1.2.14", + "@contentstack/cli-utilities": "~1.5.4", + "@contentstack/management": "~1.10.2", + "@oclif/core": "^2.9.3", + "big-json": "^3.2.0", + "bluebird": "^3.7.2", + "chalk": "^4.1.2", + "debug": "^4.1.0", + "fs-extra": "^11.1.1", + "lodash": "^4.17.20", + "marked": "^4.0.17", + "merge": "^2.1.1", + "mkdirp": "^1.0.4", + "promise-limit": "^2.7.0", + "tslib": "^2.4.1", + "winston": "^3.7.2" + } + } + } + }, + "axios": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.3.4.tgz", + "integrity": "sha512-toYm+Bsyl6VC5wSkfkbbNB6ROv7KY93PEBBL6xyDczaIHasAiv4wPqQ/c4RjoQzipxRD2W5g21cOqQulZ7rHwQ==", + "requires": { + "follow-redirects": "^1.15.0", + "form-data": "^4.0.0", + "proxy-from-env": "^1.1.0" + } + } } }, "@contentstack/cli-audit": { @@ -27524,7 +27779,7 @@ "@contentstack/cli-cm-bootstrap": { "version": "file:packages/contentstack-bootstrap", "requires": { - "@contentstack/cli-cm-seed": "~1.6.0", + "@contentstack/cli-cm-seed": "~1.7.0", "@contentstack/cli-command": "~1.2.14", "@contentstack/cli-utilities": "~1.5.4", "@oclif/test": "^2.2.10", @@ -27679,7 +27934,7 @@ "requires": { "@colors/colors": "^1.5.0", "@contentstack/cli-cm-export": "~1.9.0", - "@contentstack/cli-cm-import": "~1.10.0", + "@contentstack/cli-cm-import": "~1.11.0", "@contentstack/cli-command": "~1.2.14", "@contentstack/cli-utilities": "~1.5.4", "@oclif/test": "^1.2.7", @@ -28126,7 +28381,7 @@ "@contentstack/cli-cm-seed": { "version": "file:packages/contentstack-seed", "requires": { - "@contentstack/cli-cm-import": "~1.10.0", + "@contentstack/cli-cm-import": "~1.11.0", "@contentstack/cli-command": "~1.2.14", "@contentstack/cli-utilities": "~1.5.4", "@oclif/plugin-help": "^5.1.19", diff --git a/packages/contentstack-audit/README.md b/packages/contentstack-audit/README.md index aab6df95b9..0b662fc7e2 100644 --- a/packages/contentstack-audit/README.md +++ b/packages/contentstack-audit/README.md @@ -19,7 +19,7 @@ $ npm install -g @contentstack/cli-audit $ csdx COMMAND running command... $ csdx (--version|-v) -@contentstack/cli-audit/1.2.0 darwin-arm64 node-v18.11.0 +@contentstack/cli-audit/1.2.0 darwin-arm64 node-v20.8.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-auth/README.md b/packages/contentstack-auth/README.md index c62236dc78..1a65450ec5 100644 --- a/packages/contentstack-auth/README.md +++ b/packages/contentstack-auth/README.md @@ -18,7 +18,7 @@ $ npm install -g @contentstack/cli-auth $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-auth/1.3.15 darwin-arm64 node-v18.11.0 +@contentstack/cli-auth/1.3.15 darwin-arm64 node-v20.8.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-bootstrap/README.md b/packages/contentstack-bootstrap/README.md index d419b51e39..6a14b04412 100644 --- a/packages/contentstack-bootstrap/README.md +++ b/packages/contentstack-bootstrap/README.md @@ -15,7 +15,7 @@ $ npm install -g @contentstack/cli-cm-bootstrap $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-cm-bootstrap/1.6.0 darwin-arm64 node-v18.11.0 +@contentstack/cli-cm-bootstrap/1.7.0 darwin-arm64 node-v20.8.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-bootstrap/package.json b/packages/contentstack-bootstrap/package.json index e8914a7b3e..d703b843e7 100644 --- a/packages/contentstack-bootstrap/package.json +++ b/packages/contentstack-bootstrap/package.json @@ -1,7 +1,7 @@ { "name": "@contentstack/cli-cm-bootstrap", "description": "Bootstrap contentstack apps", - "version": "1.6.0", + "version": "1.7.0", "author": "Contentstack", "bugs": "https://github.com/contentstack/cli/issues", "scripts": { @@ -17,7 +17,7 @@ "test:report": "nyc --reporter=lcov mocha \"test/**/*.test.js\"" }, "dependencies": { - "@contentstack/cli-cm-seed": "~1.6.0", + "@contentstack/cli-cm-seed": "~1.7.0", "@contentstack/cli-command": "~1.2.14", "@contentstack/cli-utilities": "~1.5.4", "inquirer": "8.2.4", diff --git a/packages/contentstack-branches/README.md b/packages/contentstack-branches/README.md index 616c388c76..9587da605b 100755 --- a/packages/contentstack-branches/README.md +++ b/packages/contentstack-branches/README.md @@ -37,7 +37,7 @@ $ npm install -g @contentstack/cli-cm-branches $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-cm-branches/1.0.15 darwin-arm64 node-v18.11.0 +@contentstack/cli-cm-branches/1.0.15 darwin-arm64 node-v20.8.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-bulk-publish/README.md b/packages/contentstack-bulk-publish/README.md index 0326c48798..203ca12d63 100644 --- a/packages/contentstack-bulk-publish/README.md +++ b/packages/contentstack-bulk-publish/README.md @@ -18,7 +18,7 @@ $ npm install -g @contentstack/cli-cm-bulk-publish $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-cm-bulk-publish/1.3.13 darwin-arm64 node-v18.11.0 +@contentstack/cli-cm-bulk-publish/1.3.13 darwin-arm64 node-v20.8.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-clone/README.md b/packages/contentstack-clone/README.md index f7028b4dc1..b93bca2f5e 100644 --- a/packages/contentstack-clone/README.md +++ b/packages/contentstack-clone/README.md @@ -16,7 +16,7 @@ $ npm install -g @contentstack/cli-cm-clone $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-cm-clone/1.6.0 darwin-arm64 node-v18.11.0 +@contentstack/cli-cm-clone/1.7.0 darwin-arm64 node-v20.8.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-clone/package.json b/packages/contentstack-clone/package.json index d4b345e29f..100b96abbc 100644 --- a/packages/contentstack-clone/package.json +++ b/packages/contentstack-clone/package.json @@ -1,12 +1,12 @@ { "name": "@contentstack/cli-cm-clone", "description": "Contentstack stack clone plugin", - "version": "1.6.0", + "version": "1.7.0", "author": "Contentstack", "bugs": "https://github.com/rohitmishra209/cli-cm-clone/issues", "dependencies": { "@contentstack/cli-cm-export": "~1.9.0", - "@contentstack/cli-cm-import": "~1.10.0", + "@contentstack/cli-cm-import": "~1.11.0", "@contentstack/cli-command": "~1.2.14", "@contentstack/cli-utilities": "~1.5.4", "@colors/colors": "^1.5.0", diff --git a/packages/contentstack-config/README.md b/packages/contentstack-config/README.md index 4edacb273f..f47f435180 100644 --- a/packages/contentstack-config/README.md +++ b/packages/contentstack-config/README.md @@ -18,7 +18,7 @@ $ npm install -g @contentstack/cli-config $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-config/1.4.13 darwin-arm64 node-v18.11.0 +@contentstack/cli-config/1.4.13 darwin-arm64 node-v20.8.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-export/README.md b/packages/contentstack-export/README.md index 5fcc1c51cc..c36ef67f18 100755 --- a/packages/contentstack-export/README.md +++ b/packages/contentstack-export/README.md @@ -48,7 +48,7 @@ $ npm install -g @contentstack/cli-cm-export $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-cm-export/1.9.2 darwin-arm64 node-v18.11.0 +@contentstack/cli-cm-export/1.9.2 darwin-arm64 node-v20.8.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-import/README.md b/packages/contentstack-import/README.md index 9af92f71dc..960b49f1de 100644 --- a/packages/contentstack-import/README.md +++ b/packages/contentstack-import/README.md @@ -47,7 +47,7 @@ $ npm install -g @contentstack/cli-cm-import $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-cm-import/1.10.0 darwin-arm64 node-v18.11.0 +@contentstack/cli-cm-import/1.11.0 darwin-arm64 node-v20.8.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-import/package.json b/packages/contentstack-import/package.json index 2a5295944f..6532883888 100644 --- a/packages/contentstack-import/package.json +++ b/packages/contentstack-import/package.json @@ -1,7 +1,7 @@ { "name": "@contentstack/cli-cm-import", "description": "Contentstack CLI plugin to import content into stack", - "version": "1.10.1", + "version": "1.11.0", "author": "Contentstack", "bugs": "https://github.com/contentstack/cli/issues", "dependencies": { diff --git a/packages/contentstack-launch/README.md b/packages/contentstack-launch/README.md index 7b101d9976..d939bda965 100755 --- a/packages/contentstack-launch/README.md +++ b/packages/contentstack-launch/README.md @@ -19,7 +19,7 @@ $ npm install -g @contentstack/cli-launch $ csdx COMMAND running command... $ csdx (--version|-v) -@contentstack/cli-launch/1.0.13 darwin-arm64 node-v18.11.0 +@contentstack/cli-launch/1.0.13 darwin-arm64 node-v20.8.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-migrate-rte/README.md b/packages/contentstack-migrate-rte/README.md index 11d5163944..7cb9201ea9 100644 --- a/packages/contentstack-migrate-rte/README.md +++ b/packages/contentstack-migrate-rte/README.md @@ -16,7 +16,7 @@ $ npm install -g @contentstack/cli-cm-migrate-rte $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-cm-migrate-rte/1.4.13 darwin-arm64 node-v18.11.0 +@contentstack/cli-cm-migrate-rte/1.4.13 darwin-arm64 node-v20.8.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-migration/README.md b/packages/contentstack-migration/README.md index 5ea10489e7..fbed0cb23b 100644 --- a/packages/contentstack-migration/README.md +++ b/packages/contentstack-migration/README.md @@ -21,7 +21,7 @@ $ npm install -g @contentstack/cli-migration $ csdx COMMAND running command... $ csdx (--version) -@contentstack/cli-migration/1.3.14 darwin-arm64 node-v18.11.0 +@contentstack/cli-migration/1.3.14 darwin-arm64 node-v20.8.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND diff --git a/packages/contentstack-seed/package.json b/packages/contentstack-seed/package.json index e98d8582f8..2563d602a4 100644 --- a/packages/contentstack-seed/package.json +++ b/packages/contentstack-seed/package.json @@ -1,11 +1,11 @@ { "name": "@contentstack/cli-cm-seed", "description": "create a Stack from existing content types, entries, assets, etc.", - "version": "1.6.1", + "version": "1.7.0", "author": "Contentstack", "bugs": "https://github.com/contentstack/cli/issues", "dependencies": { - "@contentstack/cli-cm-import": "~1.10.0", + "@contentstack/cli-cm-import": "~1.11.0", "@contentstack/cli-command": "~1.2.14", "@contentstack/cli-utilities": "~1.5.4", "inquirer": "8.2.4", @@ -73,4 +73,4 @@ "version": "oclif readme && git add README.md", "clean": "rm -rf ./node_modules tsconfig.build.tsbuildinfo" } -} +} \ No newline at end of file diff --git a/packages/contentstack/README.md b/packages/contentstack/README.md index 82a67213bf..dee6071803 100644 --- a/packages/contentstack/README.md +++ b/packages/contentstack/README.md @@ -18,7 +18,7 @@ $ npm install -g @contentstack/cli $ csdx COMMAND running command... $ csdx (--version|-v) -@contentstack/cli/1.10.0 darwin-arm64 node-v18.11.0 +@contentstack/cli/1.11.0 darwin-arm64 node-v20.8.0 $ csdx --help [COMMAND] USAGE $ csdx COMMAND @@ -2987,7 +2987,7 @@ DESCRIPTION Display help for csdx. ``` -_See code: [@oclif/plugin-help](https://github.com/oclif/plugin-help/blob/v5.2.20/src/commands/help.ts)_ +_See code: [@oclif/plugin-help](https://github.com/oclif/plugin-help/blob/v5.2.14/src/commands/help.ts)_ ## `csdx launch` @@ -3285,7 +3285,7 @@ EXAMPLES $ csdx plugins ``` -_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.8.4/src/commands/plugins/index.ts)_ +_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.3.2/src/commands/plugins/index.ts)_ ## `csdx plugins:install PLUGIN...` @@ -3350,7 +3350,7 @@ EXAMPLES $ csdx plugins:inspect myplugin ``` -_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.8.4/src/commands/plugins/inspect.ts)_ +_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.3.2/src/commands/plugins/inspect.ts)_ ## `csdx plugins:install PLUGIN...` @@ -3390,7 +3390,7 @@ EXAMPLES $ csdx plugins:install someuser/someplugin ``` -_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.8.4/src/commands/plugins/install.ts)_ +_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.3.2/src/commands/plugins/install.ts)_ ## `csdx plugins:link PLUGIN` @@ -3419,7 +3419,7 @@ EXAMPLES $ csdx plugins:link myplugin ``` -_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.8.4/src/commands/plugins/link.ts)_ +_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.3.2/src/commands/plugins/link.ts)_ ## `csdx plugins:uninstall PLUGIN...` @@ -3467,7 +3467,7 @@ ALIASES $ csdx plugins:remove ``` -_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.8.4/src/commands/plugins/uninstall.ts)_ +_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.3.2/src/commands/plugins/uninstall.ts)_ ## `csdx plugins:uninstall PLUGIN...` @@ -3508,7 +3508,7 @@ DESCRIPTION Update installed plugins. ``` -_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.8.4/src/commands/plugins/update.ts)_ +_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v3.3.2/src/commands/plugins/update.ts)_ ## `csdx tokens` diff --git a/packages/contentstack/package.json b/packages/contentstack/package.json index aa73bc4db4..6e12991588 100755 --- a/packages/contentstack/package.json +++ b/packages/contentstack/package.json @@ -1,7 +1,7 @@ { "name": "@contentstack/cli", "description": "Command-line tool (CLI) to interact with Contentstack", - "version": "1.10.0", + "version": "1.11.0", "author": "Contentstack", "bin": { "csdx": "./bin/run" @@ -30,7 +30,7 @@ "@contentstack/cli-cm-clone": "~1.6.0", "@contentstack/cli-cm-export": "~1.9.2", "@contentstack/cli-cm-export-to-csv": "~1.4.4", - "@contentstack/cli-cm-import": "~1.10.0", + "@contentstack/cli-cm-import": "~1.11.0", "@contentstack/cli-cm-migrate-rte": "~1.4.13", "@contentstack/cli-cm-seed": "~1.6.0", "@contentstack/cli-command": "~1.2.14", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index f313c92e47..f55128c570 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -18,7 +18,7 @@ importers: '@contentstack/cli-cm-clone': ~1.6.0 '@contentstack/cli-cm-export': ~1.9.2 '@contentstack/cli-cm-export-to-csv': ~1.4.4 - '@contentstack/cli-cm-import': ~1.10.0 + '@contentstack/cli-cm-import': ~1.11.0 '@contentstack/cli-cm-migrate-rte': ~1.4.13 '@contentstack/cli-cm-seed': ~1.6.0 '@contentstack/cli-command': ~1.2.14 @@ -66,15 +66,15 @@ importers: dependencies: '@contentstack/cli-audit': link:../contentstack-audit '@contentstack/cli-auth': link:../contentstack-auth - '@contentstack/cli-cm-bootstrap': link:../contentstack-bootstrap + '@contentstack/cli-cm-bootstrap': 1.6.0_4cwpohsqfwah7meg2kctgglnwi '@contentstack/cli-cm-branches': link:../contentstack-branches '@contentstack/cli-cm-bulk-publish': link:../contentstack-bulk-publish - '@contentstack/cli-cm-clone': link:../contentstack-clone + '@contentstack/cli-cm-clone': 1.6.0_4qcp7qp4jxxdgb4qbxgwox4hwq '@contentstack/cli-cm-export': link:../contentstack-export '@contentstack/cli-cm-export-to-csv': link:../contentstack-export-to-csv '@contentstack/cli-cm-import': link:../contentstack-import '@contentstack/cli-cm-migrate-rte': link:../contentstack-migrate-rte - '@contentstack/cli-cm-seed': link:../contentstack-seed + '@contentstack/cli-cm-seed': 1.6.0_4cwpohsqfwah7meg2kctgglnwi '@contentstack/cli-command': link:../contentstack-command '@contentstack/cli-config': link:../contentstack-config '@contentstack/cli-launch': link:../contentstack-launch @@ -241,7 +241,7 @@ importers: packages/contentstack-bootstrap: specifiers: - '@contentstack/cli-cm-seed': ~1.6.0 + '@contentstack/cli-cm-seed': ~1.7.0 '@contentstack/cli-command': ~1.2.14 '@contentstack/cli-utilities': ~1.5.4 '@oclif/test': ^2.2.10 @@ -416,7 +416,7 @@ importers: specifiers: '@colors/colors': ^1.5.0 '@contentstack/cli-cm-export': ~1.9.0 - '@contentstack/cli-cm-import': ~1.10.0 + '@contentstack/cli-cm-import': ~1.11.0 '@contentstack/cli-command': ~1.2.14 '@contentstack/cli-utilities': ~1.5.4 '@oclif/test': ^1.2.7 @@ -968,7 +968,7 @@ importers: packages/contentstack-seed: specifiers: - '@contentstack/cli-cm-import': ~1.10.0 + '@contentstack/cli-cm-import': ~1.11.0 '@contentstack/cli-command': ~1.2.14 '@contentstack/cli-utilities': ~1.5.4 '@oclif/plugin-help': ^5.1.19 @@ -1549,6 +1549,182 @@ packages: engines: {node: '>=0.1.90'} dev: false + /@contentstack/cli-cm-bootstrap/1.6.0_4cwpohsqfwah7meg2kctgglnwi: + resolution: {integrity: sha512-X1UB4lotUwCYs/Lyc4kXTwVZDF5n0iwNP3l31ej74j8md6esVlAO89uOio93NE2hEcEMUBui7Qcx+KnUz9kf/A==} + engines: {node: '>=14.0.0'} + dependencies: + '@contentstack/cli-cm-seed': 1.6.0_4cwpohsqfwah7meg2kctgglnwi + '@contentstack/cli-command': 1.2.14_4qcp7qp4jxxdgb4qbxgwox4hwq + '@contentstack/cli-utilities': 1.5.4_4qcp7qp4jxxdgb4qbxgwox4hwq + inquirer: 8.2.4 + mkdirp: 1.0.4 + tar: 6.1.15 + transitivePeerDependencies: + - '@swc/core' + - '@swc/wasm' + - '@types/node' + - debug + - encoding + - supports-color + - typescript + dev: false + + /@contentstack/cli-cm-clone/1.6.0_4qcp7qp4jxxdgb4qbxgwox4hwq: + resolution: {integrity: sha512-b/NxS1PhMa0RlGxjrRaeggqVNttrkhC3ptLbXjh+Cdfmonrdei9x2/4OkA6Q0McIVlsGPLb4RaoUr+cm5+ZyKA==} + engines: {node: '>=14.0.0'} + dependencies: + '@colors/colors': 1.6.0 + '@contentstack/cli-cm-export': 1.9.2_4qcp7qp4jxxdgb4qbxgwox4hwq + '@contentstack/cli-cm-import': 1.10.0_4qcp7qp4jxxdgb4qbxgwox4hwq + '@contentstack/cli-command': 1.2.14_4qcp7qp4jxxdgb4qbxgwox4hwq + '@contentstack/cli-utilities': 1.5.4_4qcp7qp4jxxdgb4qbxgwox4hwq + async: 3.2.4 + chalk: 4.1.2 + child_process: 1.0.2 + fancy-test: 1.4.10 + inquirer: 8.2.4 + ora: 5.4.1 + prompt: 1.3.0 + rimraf: 3.0.2 + winston: 3.10.0 + transitivePeerDependencies: + - '@swc/core' + - '@swc/wasm' + - '@types/node' + - encoding + - supports-color + - typescript + dev: false + + /@contentstack/cli-cm-export/1.9.2_4qcp7qp4jxxdgb4qbxgwox4hwq: + resolution: {integrity: sha512-IlCC20swlBWGIJ3alPvZBNMflG3PeAc2DWywuG0/V4x3y1I/E7JvXxsdAAmsCCrziH8vmNIjyIuwqKSL3lKKmA==} + engines: {node: '>=14.0.0'} + dependencies: + '@contentstack/cli-command': 1.2.14_4qcp7qp4jxxdgb4qbxgwox4hwq + '@contentstack/cli-utilities': 1.5.4_4qcp7qp4jxxdgb4qbxgwox4hwq + '@oclif/core': 2.15.0_4qcp7qp4jxxdgb4qbxgwox4hwq + async: 3.2.4 + big-json: 3.2.0 + bluebird: 3.7.2 + chalk: 4.1.2 + is-valid-path: 0.1.1 + lodash: 4.17.21 + merge: 2.1.1 + mkdirp: 1.0.4 + path: 0.12.7 + progress-stream: 2.0.0 + promise-limit: 2.7.0 + proxyquire: 2.1.3 + tslib: 2.6.2 + winston: 3.10.0 + transitivePeerDependencies: + - '@swc/core' + - '@swc/wasm' + - '@types/node' + - encoding + - supports-color + - typescript + dev: false + + /@contentstack/cli-cm-import/1.10.0_4qcp7qp4jxxdgb4qbxgwox4hwq: + resolution: {integrity: sha512-Jn9grDE2J1c4iGBcPv24Q8lj/ozgfD9QNbJcn+1a6oGjA6OE+a39agQwi04nByBw4xRtbLUmHa4nfFRaF7qkvQ==} + engines: {node: '>=14.0.0'} + dependencies: + '@contentstack/cli-command': 1.2.14_4qcp7qp4jxxdgb4qbxgwox4hwq + '@contentstack/cli-utilities': 1.5.4_4qcp7qp4jxxdgb4qbxgwox4hwq + '@contentstack/management': 1.10.2_debug@4.3.4 + '@oclif/core': 2.15.0_4qcp7qp4jxxdgb4qbxgwox4hwq + big-json: 3.2.0 + bluebird: 3.7.2 + chalk: 4.1.2 + debug: 4.3.4 + fs-extra: 11.1.1 + lodash: 4.17.21 + marked: 4.3.0 + merge: 2.1.1 + mkdirp: 1.0.4 + promise-limit: 2.7.0 + tslib: 2.6.2 + winston: 3.10.0 + transitivePeerDependencies: + - '@swc/core' + - '@swc/wasm' + - '@types/node' + - encoding + - supports-color + - typescript + dev: false + + /@contentstack/cli-cm-seed/1.6.0_4cwpohsqfwah7meg2kctgglnwi: + resolution: {integrity: sha512-aAhi3iuwbo/bv/j0RWS+OesdTqrQkEsIwVfxVOSUCDUrvJ29O7289pb07L0bO3THkTCz0d5bTT+oj5KK68ZWuA==} + engines: {node: '>=14.0.0'} + dependencies: + '@contentstack/cli-cm-import': 1.10.0_4qcp7qp4jxxdgb4qbxgwox4hwq + '@contentstack/cli-command': 1.2.14_4qcp7qp4jxxdgb4qbxgwox4hwq + '@contentstack/cli-utilities': 1.5.4_4qcp7qp4jxxdgb4qbxgwox4hwq + axios: 1.3.4_debug@4.3.4 + inquirer: 8.2.4 + mkdirp: 1.0.4 + tar: 6.1.15 + tmp: 0.2.1 + tslib: 2.6.2 + transitivePeerDependencies: + - '@swc/core' + - '@swc/wasm' + - '@types/node' + - debug + - encoding + - supports-color + - typescript + dev: false + + /@contentstack/cli-command/1.2.14_4qcp7qp4jxxdgb4qbxgwox4hwq: + resolution: {integrity: sha512-igoJD8yrXnErn1DZi32k1rcbSPD+uXI7+k9RlMhvSwpb8gTKRJt+9p/OEqDWnJjPkvLdMrxUU+bHOsqxhd9b1g==} + engines: {node: '>=14.0.0'} + dependencies: + '@contentstack/cli-utilities': 1.5.4_4qcp7qp4jxxdgb4qbxgwox4hwq + contentstack: 3.17.1 + transitivePeerDependencies: + - '@swc/core' + - '@swc/wasm' + - '@types/node' + - encoding + - supports-color + - typescript + dev: false + + /@contentstack/cli-utilities/1.5.4_4qcp7qp4jxxdgb4qbxgwox4hwq: + resolution: {integrity: sha512-LbigeaA31uP/SMHTxI9CYH30xR9Br/3Lp+/WGcW34zvKkJ4t3Jej4ADAv1LztIY6oaVtK3MLYEwo/juvhptUAQ==} + dependencies: + '@contentstack/management': 1.10.2_debug@4.3.4 + '@oclif/core': 2.15.0_4qcp7qp4jxxdgb4qbxgwox4hwq + axios: 1.3.4_debug@4.3.4 + chalk: 4.1.2 + cli-cursor: 3.1.0 + cli-table: 0.3.11 + conf: 10.2.0 + debug: 4.3.4 + figures: 3.2.0 + inquirer: 8.2.4 + inquirer-search-checkbox: 1.0.0 + inquirer-search-list: 1.2.6 + lodash: 4.17.21 + mkdirp: 1.0.4 + open: 8.4.2 + ora: 5.4.1 + rxjs: 6.6.7 + unique-string: 2.0.0 + uuid: 9.0.1 + winston: 3.10.0 + xdg-basedir: 4.0.0 + transitivePeerDependencies: + - '@swc/core' + - '@swc/wasm' + - '@types/node' + - supports-color + - typescript + dev: false + /@contentstack/json-rte-serializer/2.0.2: resolution: {integrity: sha512-mGRuXXYY4Ao0MTWUV/1aNwk5DCcNtbJA2uOA1v7t/IzSqSF4jKuz+RFZLYtSPz8vqBtPT2AgKwfs5mVB4cnYRA==} dependencies: @@ -4535,6 +4711,16 @@ packages: xml2js: 0.5.0 dev: true + /axios/1.3.4_debug@4.3.4: + resolution: {integrity: sha512-toYm+Bsyl6VC5wSkfkbbNB6ROv7KY93PEBBL6xyDczaIHasAiv4wPqQ/c4RjoQzipxRD2W5g21cOqQulZ7rHwQ==} + dependencies: + follow-redirects: 1.15.2_debug@4.3.4 + form-data: 4.0.0 + proxy-from-env: 1.1.0 + transitivePeerDependencies: + - debug + dev: false + /axios/1.5.0_debug@4.3.4: resolution: {integrity: sha512-D4DdjDo5CY50Qms0qGQTTw6Q44jl7zRwY7bthds06pUGfChBCTcQs+N743eFWGEd6pRTMd6A+I87aWyFV5wiZQ==} dependencies: From 256a5f2c5a0d9e98c67129e355b1f29b3e09547e Mon Sep 17 00:00:00 2001 From: shafeeqd959 Date: Tue, 31 Oct 2023 18:19:10 +0530 Subject: [PATCH 08/41] updated type --- packages/contentstack-import/src/import/modules/assets.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/contentstack-import/src/import/modules/assets.ts b/packages/contentstack-import/src/import/modules/assets.ts index 5baca94554..c3b4e8ec4a 100644 --- a/packages/contentstack-import/src/import/modules/assets.ts +++ b/packages/contentstack-import/src/import/modules/assets.ts @@ -29,7 +29,7 @@ export default class ImportAssets extends BaseClass { private assetsUidMap: Record = {}; private assetsUrlMap: Record = {}; private assetsFolderMap: Record = {}; - private rootFolder: { uid: any; name: any; parent_uid: unknown; created_at: any }; + private rootFolder: { uid: string; name: string; parent_uid: string; created_at: string }; constructor({ importConfig, stackAPIClient }: ModuleClassParams) { super({ importConfig, stackAPIClient }); From 2cd3f20c723c32f080dfd77ac33b4c6fa2213b48 Mon Sep 17 00:00:00 2001 From: shafeeqd959 Date: Tue, 31 Oct 2023 18:21:34 +0530 Subject: [PATCH 09/41] updated core version --- packages/contentstack/package.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/contentstack/package.json b/packages/contentstack/package.json index 6e12991588..0384889495 100755 --- a/packages/contentstack/package.json +++ b/packages/contentstack/package.json @@ -24,15 +24,15 @@ "dependencies": { "@contentstack/cli-audit": "~1.2.0", "@contentstack/cli-auth": "~1.3.15", - "@contentstack/cli-cm-bootstrap": "~1.6.0", + "@contentstack/cli-cm-bootstrap": "~1.7.0", "@contentstack/cli-cm-branches": "~1.0.15", "@contentstack/cli-cm-bulk-publish": "~1.3.13", - "@contentstack/cli-cm-clone": "~1.6.0", + "@contentstack/cli-cm-clone": "~1.7.0", "@contentstack/cli-cm-export": "~1.9.2", "@contentstack/cli-cm-export-to-csv": "~1.4.4", "@contentstack/cli-cm-import": "~1.11.0", "@contentstack/cli-cm-migrate-rte": "~1.4.13", - "@contentstack/cli-cm-seed": "~1.6.0", + "@contentstack/cli-cm-seed": "~1.7.0", "@contentstack/cli-command": "~1.2.14", "@contentstack/cli-config": "~1.4.13", "@contentstack/cli-launch": "~1.0.13", From 0d510c91145b06e3003fd55ee1c81ae55ea289a4 Mon Sep 17 00:00:00 2001 From: raj pandey Date: Wed, 1 Nov 2023 12:46:31 +0530 Subject: [PATCH 10/41] remove oclif manifest json version bump --- package-lock.json | 6 +- .../contentstack-launch/oclif.manifest.json | 430 ------------------ packages/contentstack-launch/package.json | 2 +- packages/contentstack/package.json | 2 +- pnpm-lock.yaml | 2 +- 5 files changed, 6 insertions(+), 436 deletions(-) delete mode 100644 packages/contentstack-launch/oclif.manifest.json diff --git a/package-lock.json b/package-lock.json index 9cbe4c49b4..15c0074cb7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -22851,7 +22851,7 @@ "@contentstack/cli-cm-seed": "~1.6.0", "@contentstack/cli-command": "~1.2.14", "@contentstack/cli-config": "~1.4.13", - "@contentstack/cli-launch": "~1.0.13", + "@contentstack/cli-launch": "~1.0.14", "@contentstack/cli-migration": "~1.3.14", "@contentstack/cli-utilities": "~1.5.4", "@contentstack/management": "~1.10.0", @@ -24654,7 +24654,7 @@ }, "packages/contentstack-launch": { "name": "@contentstack/cli-launch", - "version": "1.0.13", + "version": "1.0.14", "license": "MIT", "dependencies": { "@apollo/client": "^3.7.9", @@ -26973,7 +26973,7 @@ "@contentstack/cli-cm-seed": "~1.6.0", "@contentstack/cli-command": "~1.2.14", "@contentstack/cli-config": "~1.4.13", - "@contentstack/cli-launch": "~1.0.13", + "@contentstack/cli-launch": "~1.0.14", "@contentstack/cli-migration": "~1.3.14", "@contentstack/cli-utilities": "~1.5.4", "@contentstack/management": "~1.10.0", diff --git a/packages/contentstack-launch/oclif.manifest.json b/packages/contentstack-launch/oclif.manifest.json deleted file mode 100644 index 2819bc7b0b..0000000000 --- a/packages/contentstack-launch/oclif.manifest.json +++ /dev/null @@ -1,430 +0,0 @@ -{ - "version": "1.0.13", - "commands": { - "launch:base-command": { - "id": "launch:base-command", - "strict": true, - "pluginName": "@contentstack/cli-launch", - "pluginAlias": "@contentstack/cli-launch", - "pluginType": "core", - "hidden": true, - "aliases": [], - "flags": { - "data-dir": { - "name": "data-dir", - "type": "option", - "char": "d", - "description": "Current working directory", - "multiple": false - }, - "config": { - "name": "config", - "type": "option", - "char": "c", - "description": "Path to the local '.cs-launch.json' file", - "multiple": false - } - }, - "args": {} - }, - "launch:deployments": { - "id": "launch:deployments", - "description": "Show list of deployments for an environment", - "strict": true, - "pluginName": "@contentstack/cli-launch", - "pluginAlias": "@contentstack/cli-launch", - "pluginType": "core", - "hidden": false, - "aliases": [], - "examples": [ - "$ <%= config.bin %> <%= command.id %>", - "$ <%= config.bin %> <%= command.id %> -d \"current working directory\"", - "$ <%= config.bin %> <%= command.id %> -c \"path to the local config file\"", - "$ <%= config.bin %> <%= command.id %> -e \"environment number or uid\" --org= --project=" - ], - "flags": { - "data-dir": { - "name": "data-dir", - "type": "option", - "char": "d", - "description": "Current working directory", - "multiple": false - }, - "config": { - "name": "config", - "type": "option", - "char": "c", - "description": "Path to the local '.cs-launch.json' file", - "multiple": false - }, - "org": { - "name": "org", - "type": "option", - "description": "[Optional] Provide the organization UID", - "multiple": false - }, - "project": { - "name": "project", - "type": "option", - "description": "[Optional] Provide the project UID", - "multiple": false - }, - "environment": { - "name": "environment", - "type": "option", - "char": "e", - "description": "Environment name or UID", - "multiple": false - }, - "branch": { - "name": "branch", - "type": "option", - "description": "[Optional] GitHub branch name", - "hidden": true, - "multiple": false - } - }, - "args": {} - }, - "launch:environments": { - "id": "launch:environments", - "description": "Show list of environments for a project", - "strict": true, - "pluginName": "@contentstack/cli-launch", - "pluginAlias": "@contentstack/cli-launch", - "pluginType": "core", - "hidden": false, - "aliases": [], - "examples": [ - "$ <%= config.bin %> <%= command.id %>", - "$ <%= config.bin %> <%= command.id %> -d \"current working directory\"", - "$ <%= config.bin %> <%= command.id %> -c \"path to the local config file\"", - "$ <%= config.bin %> <%= command.id %> --org= --project=" - ], - "flags": { - "data-dir": { - "name": "data-dir", - "type": "option", - "char": "d", - "description": "Current working directory", - "multiple": false - }, - "config": { - "name": "config", - "type": "option", - "char": "c", - "description": "Path to the local '.cs-launch.json' file", - "multiple": false - }, - "org": { - "name": "org", - "type": "option", - "description": "[Optional] Provide the organization UID", - "multiple": false - }, - "project": { - "name": "project", - "type": "option", - "description": "[Optional] Provide the project UID", - "multiple": false - }, - "branch": { - "name": "branch", - "type": "option", - "description": "[Optional] GitHub branch name", - "hidden": true, - "multiple": false - } - }, - "args": {} - }, - "launch:functions": { - "id": "launch:functions", - "description": "Serve cloud functions", - "strict": true, - "pluginName": "@contentstack/cli-launch", - "pluginAlias": "@contentstack/cli-launch", - "pluginType": "core", - "hidden": false, - "aliases": [], - "examples": [ - "$ csdx launch:functions", - "$ csdx launch:functions --port=port", - "$ csdx launch:functions --data-dir ", - "$ csdx launch:functions --config ", - "$ csdx launch:functions --data-dir -p \"port number\"", - "$ csdx launch:functions --config --port=port" - ], - "flags": { - "data-dir": { - "name": "data-dir", - "type": "option", - "char": "d", - "description": "Current working directory", - "multiple": false - }, - "config": { - "name": "config", - "type": "option", - "char": "c", - "description": "Path to the local '.cs-launch.json' file", - "multiple": false - }, - "port": { - "name": "port", - "type": "option", - "char": "p", - "description": "Port number", - "multiple": false, - "default": "3000" - } - }, - "args": {} - }, - "launch": { - "id": "launch", - "description": "Launch related operations", - "strict": true, - "pluginName": "@contentstack/cli-launch", - "pluginAlias": "@contentstack/cli-launch", - "pluginType": "core", - "hidden": false, - "aliases": [], - "examples": [ - "<%= config.bin %> <%= command.id %>", - "<%= config.bin %> <%= command.id %> --data-dir ", - "<%= config.bin %> <%= command.id %> --config ", - "<%= config.bin %> <%= command.id %> --type ", - "<%= config.bin %> <%= command.id %> --data-dir --type ", - "<%= config.bin %> <%= command.id %> --config --type ", - "<%= config.bin %> <%= command.id %> --config --type --name= --environment= --branch= --build-command= --framework=