Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21,283 changes: 20,819 additions & 464 deletions package-lock.json

Large diffs are not rendered by default.

16 changes: 8 additions & 8 deletions packages/contentstack-audit/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ $ npm install -g @contentstack/cli-audit
$ csdx COMMAND
running command...
$ csdx (--version|-v)
@contentstack/cli-audit/1.6.3 darwin-arm64 node-v22.2.0
@contentstack/cli-audit/1.6.4 darwin-arm64 node-v22.2.0
$ csdx --help [COMMAND]
USAGE
$ csdx COMMAND
Expand Down Expand Up @@ -267,7 +267,7 @@ EXAMPLES
$ csdx plugins
```

_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.3.3/src/commands/plugins/index.ts)_
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.3.8/src/commands/plugins/index.ts)_

## `csdx plugins:add PLUGIN`

Expand Down Expand Up @@ -341,7 +341,7 @@ EXAMPLES
$ csdx plugins:inspect myplugin
```

_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.3.3/src/commands/plugins/inspect.ts)_
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.3.8/src/commands/plugins/inspect.ts)_

## `csdx plugins:install PLUGIN`

Expand Down Expand Up @@ -390,7 +390,7 @@ EXAMPLES
$ csdx plugins:install someuser/someplugin
```

_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.3.3/src/commands/plugins/install.ts)_
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.3.8/src/commands/plugins/install.ts)_

## `csdx plugins:link PATH`

Expand Down Expand Up @@ -420,7 +420,7 @@ EXAMPLES
$ csdx plugins:link myplugin
```

_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.3.3/src/commands/plugins/link.ts)_
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.3.8/src/commands/plugins/link.ts)_

## `csdx plugins:remove [PLUGIN]`

Expand Down Expand Up @@ -461,7 +461,7 @@ FLAGS
--reinstall Reinstall all plugins after uninstalling.
```

_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.3.3/src/commands/plugins/reset.ts)_
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.3.8/src/commands/plugins/reset.ts)_

## `csdx plugins:uninstall [PLUGIN]`

Expand Down Expand Up @@ -489,7 +489,7 @@ EXAMPLES
$ csdx plugins:uninstall myplugin
```

_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.3.3/src/commands/plugins/uninstall.ts)_
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.3.8/src/commands/plugins/uninstall.ts)_

## `csdx plugins:unlink [PLUGIN]`

Expand Down Expand Up @@ -533,5 +533,5 @@ DESCRIPTION
Update installed plugins.
```

_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.3.3/src/commands/plugins/update.ts)_
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.3.8/src/commands/plugins/update.ts)_
<!-- commandsstop -->
6 changes: 3 additions & 3 deletions packages/contentstack-audit/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@contentstack/cli-audit",
"version": "1.6.3",
"version": "1.6.4",
"description": "Contentstack audit plugin",
"author": "Contentstack CLI",
"homepage": "https://github.com/contentstack/cli",
Expand All @@ -18,8 +18,8 @@
"/oclif.manifest.json"
],
"dependencies": {
"@contentstack/cli-command": "~1.2.18",
"@contentstack/cli-utilities": "~1.6.3",
"@contentstack/cli-command": "~1.2.19",
"@contentstack/cli-utilities": "~1.7.0",
"@oclif/plugin-help": "^5",
"@oclif/plugin-plugins": "^5.0.0",
"chalk": "^4.1.2",
Expand Down
2 changes: 1 addition & 1 deletion packages/contentstack-auth/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ $ npm install -g @contentstack/cli-auth
$ csdx COMMAND
running command...
$ csdx (--version)
@contentstack/cli-auth/1.3.19 darwin-arm64 node-v22.2.0
@contentstack/cli-auth/1.3.20 darwin-arm64 node-v22.2.0
$ csdx --help [COMMAND]
USAGE
$ csdx COMMAND
Expand Down
6 changes: 3 additions & 3 deletions packages/contentstack-auth/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@contentstack/cli-auth",
"description": "Contentstack CLI plugin for authentication activities",
"version": "1.3.19",
"version": "1.3.20",
"author": "Contentstack",
"bugs": "https://github.com/contentstack/cli/issues",
"scripts": {
Expand All @@ -22,8 +22,8 @@
"test:unit:report": "nyc --extension .ts mocha --forbid-only \"test/unit/**/*.test.ts\""
},
"dependencies": {
"@contentstack/cli-command": "~1.2.18",
"@contentstack/cli-utilities": "~1.6.3",
"@contentstack/cli-command": "~1.2.19",
"@contentstack/cli-utilities": "~1.7.0",
"chalk": "^4.0.0",
"debug": "^4.1.1",
"inquirer": "8.2.4",
Expand Down
16 changes: 3 additions & 13 deletions packages/contentstack-auth/src/commands/auth/login.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ import {
authHandler as oauthHandler,
flags,
managementSDKClient,
FlagInput
FlagInput,
formatError
} from '@contentstack/cli-utilities';
import { User } from '../../interfaces';
import { authHandler, interactive } from '../../utils';
Expand Down Expand Up @@ -64,18 +65,7 @@ export default class LoginCommand extends BaseCommand<typeof LoginCommand> {
await this.login(username, password);
}
} catch (error) {
let errorMessage = '';
if (error) {
if (error.message) {
if (error.message.message) {
errorMessage = error.message.message;
} else {
errorMessage = error.message;
}
} else {
errorMessage = error;
}
}
let errorMessage = formatError(error) || 'Something went wrong while logging. Please try again.';
this.logger.error('login failed', errorMessage);
cliux.error('CLI_AUTH_LOGIN_FAILED');
cliux.error(errorMessage);
Expand Down
16 changes: 3 additions & 13 deletions packages/contentstack-auth/src/commands/auth/logout.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import {
authHandler as oauthHandler,
managementSDKClient,
FlagInput,
formatError,
} from '@contentstack/cli-utilities';

import { authHandler } from '../../utils';
Expand Down Expand Up @@ -54,7 +55,7 @@ export default class LogoutCommand extends BaseCommand<typeof LogoutCommand> {
if (await oauthHandler.isAuthorisationTypeBasic()) {
await authHandler.logout(configHandler.get('authtoken'));
} else if (await oauthHandler.isAuthorisationTypeOAuth()) {
await oauthHandler.oauthLogout()
await oauthHandler.oauthLogout();
}
cliux.loader('');
this.logger.info('successfully logged out');
Expand All @@ -63,18 +64,7 @@ export default class LogoutCommand extends BaseCommand<typeof LogoutCommand> {
cliux.success('CLI_AUTH_LOGOUT_ALREADY');
}
} catch (error) {
let errorMessage = '';
if (error) {
if (error.message) {
if (error.message.message) {
errorMessage = error.message.message;
} else {
errorMessage = error.message;
}
} else {
errorMessage = error;
}
}
let errorMessage = formatError(error) || 'Something went wrong while logging out. Please try again.';

this.logger.error('Logout failed', errorMessage);
cliux.print('CLI_AUTH_LOGOUT_FAILED', { color: 'yellow' });
Expand Down
6 changes: 4 additions & 2 deletions packages/contentstack-auth/src/commands/auth/tokens/add.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import {
HttpClient,
messageHandler,
Flags,
formatError,
} from '@contentstack/cli-utilities';
import { askTokenType } from '../../../utils/interactive';
import { BaseCommand } from '../../../base-command';
Expand Down Expand Up @@ -159,9 +160,10 @@ export default class TokensAddCommand extends BaseCommand<typeof TokensAddComman
cliux.success('CLI_AUTH_TOKENS_ADD_SUCCESS');
}
} catch (error) {
this.logger.error('token add error', error.message);
let errorMessage = formatError(error) || 'Something went wrong while adding token. Please try again.';
this.logger.error('token add error', errorMessage);
cliux.print('CLI_AUTH_TOKENS_ADD_FAILED', { color: 'yellow' });
cliux.error(error.message.message ? error.message.message : error.message);
cliux.error(errorMessage);
}
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Command } from '@contentstack/cli-command';
import { cliux, configHandler } from '@contentstack/cli-utilities';
import { cliux, configHandler, formatError } from '@contentstack/cli-utilities';
import { BaseCommand } from '../../../base-command';
export default class TokensListCommand extends BaseCommand<typeof TokensListCommand> {
static aliases = ['tokens'];
Expand Down Expand Up @@ -52,9 +52,10 @@ export default class TokensListCommand extends BaseCommand<typeof TokensListComm
cliux.print('CLI_AUTH_TOKENS_LIST_NO_TOKENS');
}
} catch (error) {
this.logger.error('Token list error', error.message);
let errorMessage = formatError(error) || 'Something went wrong while fetching tokens. Please try again.';
this.logger.error('Token list error', errorMessage);
cliux.print('CLI_AUTH_TOKENS_LIST_FAILED', { color: 'yellow' });
cliux.print(error.message, { color: 'red' });
cliux.print(errorMessage, { color: 'red' });
}
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Command } from '@contentstack/cli-command';
import { cliux, configHandler, flags, FlagInput } from '@contentstack/cli-utilities';
import { cliux, configHandler, flags, FlagInput, formatError } from '@contentstack/cli-utilities';
import { BaseCommand } from '../../../base-command';

export default class TokensRemoveCommand extends BaseCommand<typeof TokensRemoveCommand> {
Expand Down Expand Up @@ -58,9 +58,10 @@ export default class TokensRemoveCommand extends BaseCommand<typeof TokensRemove
this.logger.info('Token removed successfully !!', element);
});
} catch (error) {
this.logger.error('Token remove error', error.message);
let errorMessage = formatError(error) || 'Something went wrong while removing token. Please try again.';
this.logger.error('Token remove error', errorMessage);
cliux.print('CLI_AUTH_TOKENS_REMOVE_FAILED', { color: 'yellow' });
cliux.print(error.message, { color: 'red' });
cliux.print(errorMessage, { color: 'red' });
}
}
}
7 changes: 4 additions & 3 deletions packages/contentstack-auth/src/commands/auth/whoami.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Command } from '@contentstack/cli-command';
import { cliux } from '@contentstack/cli-utilities';
import { cliux, formatError } from '@contentstack/cli-utilities';
import { BaseCommand } from '../../base-command';

export default class WhoamiCommand extends BaseCommand<typeof WhoamiCommand> {
Expand All @@ -19,9 +19,10 @@ export default class WhoamiCommand extends BaseCommand<typeof WhoamiCommand> {
cliux.error('CLI_AUTH_WHOAMI_FAILED');
}
} catch (error) {
this.logger.error('whoami error', error.message);
let errorMessage = formatError(error) || 'Something went wrong. Please try again.';
this.logger.error('whoami error', errorMessage);
cliux.print('CLI_AUTH_WHOAMI_FAILED', { color: 'yellow' });
cliux.print(error.message, { color: 'red' });
cliux.print(errorMessage, { color: 'red' });
}
}
}
2 changes: 1 addition & 1 deletion packages/contentstack-bootstrap/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ $ npm install -g @contentstack/cli-cm-bootstrap
$ csdx COMMAND
running command...
$ csdx (--version)
@contentstack/cli-cm-bootstrap/1.9.3 darwin-arm64 node-v22.2.0
@contentstack/cli-cm-bootstrap/1.9.4 darwin-arm64 node-v22.2.0
$ csdx --help [COMMAND]
USAGE
$ csdx COMMAND
Expand Down
6 changes: 3 additions & 3 deletions packages/contentstack-bootstrap/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@contentstack/cli-cm-bootstrap",
"description": "Bootstrap contentstack apps",
"version": "1.9.3",
"version": "1.9.4",
"author": "Contentstack",
"bugs": "https://github.com/contentstack/cli/issues",
"scripts": {
Expand All @@ -18,8 +18,8 @@
},
"dependencies": {
"@contentstack/cli-cm-seed": "~1.7.6",
"@contentstack/cli-command": "~1.2.18",
"@contentstack/cli-utilities": "~1.6.3",
"@contentstack/cli-command": "~1.2.19",
"@contentstack/cli-utilities": "~1.7.0",
"inquirer": "8.2.4",
"mkdirp": "^1.0.4",
"tar": "^6.2.1 "
Expand Down
2 changes: 1 addition & 1 deletion packages/contentstack-branches/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ $ npm install -g @contentstack/cli-cm-branches
$ csdx COMMAND
running command...
$ csdx (--version)
@contentstack/cli-cm-branches/1.1.1 darwin-arm64 node-v22.2.0
@contentstack/cli-cm-branches/1.1.2 darwin-arm64 node-v22.2.0
$ csdx --help [COMMAND]
USAGE
$ csdx COMMAND
Expand Down
6 changes: 3 additions & 3 deletions packages/contentstack-branches/package.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"name": "@contentstack/cli-cm-branches",
"description": "Contentstack CLI plugin to do branches operations",
"version": "1.1.1",
"version": "1.1.2",
"author": "Contentstack",
"bugs": "https://github.com/contentstack/cli/issues",
"dependencies": {
"@contentstack/cli-command": "~1.2.18",
"@contentstack/cli-utilities": "~1.6.3",
"@contentstack/cli-command": "~1.2.19",
"@contentstack/cli-utilities": "~1.7.0",
"@oclif/core": "^3.26.5",
"async": "^3.2.4",
"big-json": "^3.2.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/contentstack-bulk-publish/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ $ npm install -g @contentstack/cli-cm-bulk-publish
$ csdx COMMAND
running command...
$ csdx (--version)
@contentstack/cli-cm-bulk-publish/1.4.7 darwin-arm64 node-v22.2.0
@contentstack/cli-cm-bulk-publish/1.4.8 darwin-arm64 node-v22.2.0
$ csdx --help [COMMAND]
USAGE
$ csdx COMMAND
Expand Down
6 changes: 3 additions & 3 deletions packages/contentstack-bulk-publish/package.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"name": "@contentstack/cli-cm-bulk-publish",
"description": "Contentstack CLI plugin for bulk publish actions",
"version": "1.4.7",
"version": "1.4.8",
"author": "Contentstack",
"bugs": "https://github.com/contentstack/cli/issues",
"dependencies": {
"@contentstack/cli-command": "~1.2.18",
"@contentstack/cli-utilities": "~1.6.3",
"@contentstack/cli-command": "~1.2.19",
"@contentstack/cli-utilities": "~1.7.0",
"bluebird": "^3.7.2",
"chalk": "^4.1.2",
"dotenv": "^16.1.4",
Expand Down
2 changes: 1 addition & 1 deletion packages/contentstack-clone/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ $ npm install -g @contentstack/cli-cm-clone
$ csdx COMMAND
running command...
$ csdx (--version)
@contentstack/cli-cm-clone/1.10.6 darwin-arm64 node-v22.2.0
@contentstack/cli-cm-clone/1.10.7 darwin-arm64 node-v22.2.0
$ csdx --help [COMMAND]
USAGE
$ csdx COMMAND
Expand Down
10 changes: 5 additions & 5 deletions packages/contentstack-clone/package.json
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
{
"name": "@contentstack/cli-cm-clone",
"description": "Contentstack stack clone plugin",
"version": "1.10.6",
"version": "1.10.7",
"author": "Contentstack",
"bugs": "https://github.com/rohitmishra209/cli-cm-clone/issues",
"dependencies": {
"@colors/colors": "^1.5.0",
"@contentstack/cli-cm-export": "~1.11.5",
"@contentstack/cli-cm-import": "~1.16.1",
"@contentstack/cli-command": "~1.2.18",
"@contentstack/cli-utilities": "~1.6.3",
"@contentstack/cli-cm-export": "~1.11.6",
"@contentstack/cli-cm-import": "~1.16.2",
"@contentstack/cli-command": "~1.2.19",
"@contentstack/cli-utilities": "~1.7.0",
"async": "^3.2.4",
"chalk": "^4.1.0",
"child_process": "^1.0.2",
Expand Down
4 changes: 2 additions & 2 deletions packages/contentstack-command/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@contentstack/cli-command",
"description": "Contentstack CLI plugin for configuration",
"version": "1.2.18",
"version": "1.2.19",
"author": "Contentstack",
"main": "lib/index.js",
"types": "lib/index.d.ts",
Expand All @@ -17,7 +17,7 @@
"format": "eslint src/**/*.ts --fix"
},
"dependencies": {
"@contentstack/cli-utilities": "~1.6.3",
"@contentstack/cli-utilities": "~1.7.0",
"contentstack": "^3.10.1"
},
"devDependencies": {
Expand Down
Loading