Skip to content

Commit 9e4e28f

Browse files
authored
Merge pull request #1277 from contentstack/release/CS-43721
Release/CS-43721-Adding the GCP changes
2 parents 0259f27 + b494d9e commit 9e4e28f

13 files changed

Lines changed: 28 additions & 27 deletions

File tree

package-lock.json

Lines changed: 9 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/contentstack-branches/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
},
2727
"devDependencies": {
2828
"@contentstack/cli-auth": "~1.3.17",
29-
"@contentstack/cli-config": "~1.6.0",
29+
"@contentstack/cli-config": "~1.6.1",
3030
"@contentstack/cli-dev-dependencies": "~1.2.4",
3131
"@oclif/plugin-help": "^5.1.19",
3232
"@oclif/test": "^1.2.6",

packages/contentstack-clone/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"bugs": "https://github.com/rohitmishra209/cli-cm-clone/issues",
77
"dependencies": {
88
"@contentstack/cli-cm-export": "~1.10.4",
9-
"@contentstack/cli-cm-import": "~1.13.2",
9+
"@contentstack/cli-cm-import": "~1.13.3",
1010
"@contentstack/cli-command": "~1.2.16",
1111
"@contentstack/cli-utilities": "~1.5.11",
1212
"@colors/colors": "^1.5.0",

packages/contentstack-config/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@contentstack/cli-config",
33
"description": "Contentstack CLI plugin for configuration",
4-
"version": "1.6.0",
4+
"version": "1.6.1",
55
"author": "Contentstack",
66
"scripts": {
77
"build": "npm run clean && npm run compile",

packages/contentstack-config/src/commands/config/set/region.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ export default class RegionSetCommand extends BaseCommand<typeof RegionSetComman
8888
this.logger.error('failed to set the region', error);
8989
cliux.error(`Failed to set region due to: ${error.message}`);
9090
}
91-
} else if (['NA', 'EU', 'AZURE-NA', 'AZURE-EU'].includes(selectedRegion)) {
91+
} else if (['NA', 'EU', 'AZURE-NA', 'AZURE-EU', 'GCP-NA'].includes(selectedRegion)) {
9292
const regionDetails: Region = regionHandler.setRegion(selectedRegion);
9393
await authHandler.setConfigData('logout'); //Todo: Handle this logout flow well through logout command call
9494
cliux.success(`Region has been set to ${regionDetails.name}`);

packages/contentstack-config/src/utils/interactive.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ export const askRegions = async (): Promise<string> => {
1111
{ name: 'EU', value: 'EU' },
1212
{ name: 'AZURE-NA', value: 'AZURE-NA' },
1313
{ name: 'AZURE-EU', value: 'AZURE-EU' },
14+
{ name: 'GCP-NA', value: 'GCP-NA' },
1415
{ name: 'Custom', value: 'custom' },
1516
{ name: 'exit', value: 'exit' },
1617
],

packages/contentstack-export/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
},
2626
"devDependencies": {
2727
"@contentstack/cli-auth": "~1.3.17",
28-
"@contentstack/cli-config": "~1.6.0",
28+
"@contentstack/cli-config": "~1.6.1",
2929
"@contentstack/cli-dev-dependencies": "~1.2.4",
3030
"@oclif/plugin-help": "^5.1.19",
3131
"@oclif/test": "^2.5.6",

packages/contentstack-import/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@contentstack/cli-cm-import",
33
"description": "Contentstack CLI plugin to import content into stack",
4-
"version": "1.13.2",
4+
"version": "1.13.3",
55
"author": "Contentstack",
66
"bugs": "https://github.com/contentstack/cli/issues",
77
"dependencies": {

packages/contentstack-import/src/commands/cm/stacks/import.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ export default class ImportCommand extends Command {
141141
'success',
142142
);
143143
} catch (error) {
144-
log({ data: backupDir } as ImportConfig, `Failed to import stack content - ${formatError(error)}`, 'error');
144+
log({ data: backupDir ?? path.join(backupDir || __dirname, 'logs', 'import') } as ImportConfig, `Failed to import stack content - ${formatError(error)}`, 'error');
145145
log(
146146
{ data: backupDir } as ImportConfig,
147147
`The log has been stored at ${

packages/contentstack-import/src/utils/import-config-handler.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ const setupConfig = async (importCmdFlags: any): Promise<ImportConfig> => {
3535
const managementTokenAlias = importCmdFlags['management-token-alias'] || importCmdFlags['alias'];
3636

3737
if (managementTokenAlias) {
38-
const { token, apiKey } = configHandler.get(`tokens.${managementTokenAlias}`);
38+
const { token, apiKey } = configHandler.get(`tokens.${managementTokenAlias}`) ?? {};
3939
config.management_token = token;
4040
config.apiKey = apiKey;
4141
if (!config.management_token) {

0 commit comments

Comments
 (0)