@contentstack/cli 1.7.5 → 1.7.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -18,7 +18,7 @@ $ npm install -g @contentstack/cli
18
18
  $ csdx COMMAND
19
19
  running command...
20
20
  $ csdx (--version|-v)
21
- @contentstack/cli/1.7.5 linux-x64 node-v16.20.0
21
+ @contentstack/cli/1.7.7 linux-x64 node-v16.20.0
22
22
  $ csdx --help [COMMAND]
23
23
  USAGE
24
24
  $ csdx COMMAND
@@ -1300,14 +1300,16 @@ Migration script to migrate content from HTML RTE to JSON RTE
1300
1300
 
1301
1301
  ```
1302
1302
  USAGE
1303
- $ csdx cm:entries:migrate-html-rte [-c <value>] [-a <value>] [--content-type <value>] [--global-field] [-y] [--html-path
1304
- <value> --json-path <value>] [--delay <value>] [--locale <value>] [--batch-limit <value>]
1303
+ $ csdx cm:entries:migrate-html-rte [-c <value>] [-a <value>] [--stack-api-key <value>] [--content-type <value>]
1304
+ [--global-field] [-y] [--branch <value>] [--html-path <value> --json-path <value>] [--delay <value>] [--locale
1305
+ <value>] [--batch-limit <value>]
1305
1306
 
1306
1307
  FLAGS
1307
1308
  -a, --alias=<value> Alias(name) for the management token
1308
1309
  -c, --config-path=<value> Path to config file
1309
1310
  -y, --yes Agree to process the command with the current configuration
1310
1311
  --batch-limit=<value> [default: 50] Provide batch limit for updating entries
1312
+ --branch=<value> [optional] branch name
1311
1313
  --content-type=<value> The content type from which entries will be migrated
1312
1314
  --delay=<value> [default: 1000] Provide delay in ms between two entry update
1313
1315
  --global-field This flag is set to false by default. It indicates that current content type is a
@@ -1315,6 +1317,7 @@ FLAGS
1315
1317
  --html-path=<value> Provide path of HTML RTE to migrate
1316
1318
  --json-path=<value> Provide path of JSON RTE to migrate
1317
1319
  --locale=<value> The locale from which entries will be migrated
1320
+ --stack-api-key=<value> Stack api key to be used
1318
1321
 
1319
1322
  DESCRIPTION
1320
1323
  Migration script to migrate content from HTML RTE to JSON RTE
@@ -1814,13 +1817,14 @@ Export entries or organization users to csv using this command
1814
1817
  ```
1815
1818
  USAGE
1816
1819
  $ csdx cm:export-to-csv [--action entries|users] [-a <value>] [--org <value>] [-n <value>] [--org-name <value>]
1817
- [--locale <value>] [--content-type <value>]
1820
+ [--locale <value>] [--content-type <value>] [--branch <value>]
1818
1821
 
1819
1822
  FLAGS
1820
1823
  -a, --alias=<value> Alias of the management token
1821
1824
  -n, --stack-name=<value> Name of the stack that needs to be created as csv filename.
1822
1825
  --action=<option> Option to export data (entries, users)
1823
1826
  <options: entries|users>
1827
+ --branch=<value> Branch from which entries need to be exported
1824
1828
  --content-type=<value> Content type for which entries needs to be exported
1825
1829
  --locale=<value> Locale for which entries need to be exported
1826
1830
  --org=<value> Provide organization UID to clone org users
@@ -1840,9 +1844,9 @@ EXAMPLES
1840
1844
 
1841
1845
 
1842
1846
 
1843
- Exporting entries to csv with stack name provided
1847
+ Exporting entries to csv with stack name provided and branch name provided
1844
1848
 
1845
- $ csdx cm:export-to-csv --action <entries> --locale <locale> --alias <management-token-alias> --content-type <content-type> --stack-name <stack-name>
1849
+ $ csdx cm:export-to-csv --action <entries> --locale <locale> --alias <management-token-alias> --content-type <content-type> --stack-name <stack-name> --branch <branch-name>
1846
1850
 
1847
1851
 
1848
1852
 
@@ -1914,14 +1918,16 @@ Migration script to migrate content from HTML RTE to JSON RTE
1914
1918
 
1915
1919
  ```
1916
1920
  USAGE
1917
- $ csdx cm:migrate-rte [-c <value>] [-a <value>] [--content-type <value>] [--global-field] [-y] [--html-path
1918
- <value> --json-path <value>] [--delay <value>] [--locale <value>] [--batch-limit <value>]
1921
+ $ csdx cm:migrate-rte [-c <value>] [-a <value>] [--stack-api-key <value>] [--content-type <value>]
1922
+ [--global-field] [-y] [--branch <value>] [--html-path <value> --json-path <value>] [--delay <value>] [--locale
1923
+ <value>] [--batch-limit <value>]
1919
1924
 
1920
1925
  FLAGS
1921
1926
  -a, --alias=<value> Alias(name) for the management token
1922
1927
  -c, --config-path=<value> Path to config file
1923
1928
  -y, --yes Agree to process the command with the current configuration
1924
1929
  --batch-limit=<value> [default: 50] Provide batch limit for updating entries
1930
+ --branch=<value> [optional] branch name
1925
1931
  --content-type=<value> The content type from which entries will be migrated
1926
1932
  --delay=<value> [default: 1000] Provide delay in ms between two entry update
1927
1933
  --global-field This flag is set to false by default. It indicates that current content type is a
@@ -1929,6 +1935,7 @@ FLAGS
1929
1935
  --html-path=<value> Provide path of HTML RTE to migrate
1930
1936
  --json-path=<value> Provide path of JSON RTE to migrate
1931
1937
  --locale=<value> The locale from which entries will be migrated
1938
+ --stack-api-key=<value> Stack api key to be used
1932
1939
 
1933
1940
  DESCRIPTION
1934
1941
  Migration script to migrate content from HTML RTE to JSON RTE
@@ -2808,13 +2815,13 @@ EXAMPLES
2808
2815
 
2809
2816
  $ csdx launch:functions --port=port
2810
2817
 
2811
- $ csdx launch:logs --data-dir <path/of/current/working/dir>
2818
+ $ csdx launch:functions --data-dir <path/of/current/working/dir>
2812
2819
 
2813
- $ csdx launch:logs --config <path/to/launch/config/file>
2820
+ $ csdx launch:functions --config <path/to/launch/config/file>
2814
2821
 
2815
- $ csdx launch:logs --data-dir <path/of/current/working/dir> -p "port number"
2822
+ $ csdx launch:functions --data-dir <path/of/current/working/dir> -p "port number"
2816
2823
 
2817
- $ csdx launch:logs --config <path/to/launch/config/file> --port=port
2824
+ $ csdx launch:functions --config <path/to/launch/config/file> --port=port
2818
2825
  ```
2819
2826
 
2820
2827
  _See code: [@contentstack/cli-launch](https://github.com/contentstack/cli/blob/main/packages/contentstack-launch/dist/commands/launch/functions.ts)_
@@ -2825,13 +2832,16 @@ Show deployment or server logs
2825
2832
 
2826
2833
  ```
2827
2834
  USAGE
2828
- $ csdx launch:logs [-d <value>] [-c <value>] [-e <value>] [--deployment <value>] [--type d|s]
2835
+ $ csdx launch:logs [-d <value>] [-c <value>] [-e <value>] [--deployment <value>] [--type d|s] [--org <value>]
2836
+ [--project <value>]
2829
2837
 
2830
2838
  FLAGS
2831
2839
  -c, --config=<value> Path to the local '.cs-launch.json' file
2832
2840
  -d, --data-dir=<value> Current working directory
2833
2841
  -e, --environment=<value> Environment name or UID
2834
2842
  --deployment=<value> Deployment number or UID
2843
+ --org=<value> [Optional] Provide the organization UID
2844
+ --project=<value> [Optional] Provide the project UID
2835
2845
  --type=<option> [default: s] Choose type of flags to show logs
2836
2846
  d) Deployment logs
2837
2847
  s) Server logs
@@ -0,0 +1,8 @@
1
+ declare const _default: {
2
+ logger: {
3
+ level: string;
4
+ silent: boolean;
5
+ };
6
+ commandRegexPattern: RegExp;
7
+ };
8
+ export default _default;
package/lib/help.d.ts ADDED
@@ -0,0 +1,7 @@
1
+ import { Help } from '@oclif/core';
2
+ export default class MyHelpClass extends Help {
3
+ constructor(config: any, opts: any);
4
+ showRootHelp(): any;
5
+ showCommandHelp(command: any): any;
6
+ formatCommands(commands: any): string;
7
+ }
@@ -0,0 +1,4 @@
1
+ /**
2
+ * Set the cli context
3
+ */
4
+ export default function (opts: any): void;
@@ -0,0 +1,4 @@
1
+ /**
2
+ * Initialize the utilities
3
+ */
4
+ export default function (_opts: any): void;
@@ -0,0 +1 @@
1
+ export default function (opts: any): Promise<void>;
@@ -0,0 +1 @@
1
+ export default function (_opts: any): Promise<void>;
package/lib/index.d.ts ADDED
@@ -0,0 +1,2 @@
1
+ declare const _default: "@oclif/core";
2
+ export default _default;
@@ -0,0 +1,31 @@
1
+ import { Config, Plugin } from '@oclif/core';
2
+ export interface PrintOptions {
3
+ color?: string;
4
+ }
5
+ export interface InquirePayload {
6
+ type: string;
7
+ name: string;
8
+ message: string;
9
+ choices?: Array<any>;
10
+ transformer?: Function;
11
+ }
12
+ export interface Region {
13
+ name: string;
14
+ cma: string;
15
+ cda: string;
16
+ }
17
+ export interface Context {
18
+ id: string;
19
+ user: {
20
+ authtoken: string;
21
+ email: string;
22
+ };
23
+ region: any;
24
+ plugin: Plugin;
25
+ config: any;
26
+ info: any;
27
+ messageFilePath: any;
28
+ }
29
+ export interface CLIConfig extends Config {
30
+ context: Context;
31
+ }
@@ -0,0 +1,15 @@
1
+ export default class CsdxContext {
2
+ readonly sessionId: string;
3
+ readonly clientId: string;
4
+ readonly user?: object;
5
+ readonly region?: object;
6
+ readonly config: object;
7
+ readonly info: any;
8
+ readonly plugin: any;
9
+ readonly pluginConfig: any;
10
+ readonly messageFilePath: string;
11
+ readonly analyticsInfo: string;
12
+ flagWarningPrintState: any;
13
+ constructor(cliOpts: any, cliConfig: any);
14
+ getToken(alias: string): any;
15
+ }
@@ -0,0 +1 @@
1
+ export { default as CsdxContext } from './context-handler';
@@ -1,4 +1,4 @@
1
1
  {
2
- "version": "1.7.5",
2
+ "version": "1.7.7",
3
3
  "commands": {}
4
4
  }
package/package.json CHANGED
@@ -1,12 +1,13 @@
1
1
  {
2
2
  "name": "@contentstack/cli",
3
3
  "description": "Command-line tool (CLI) to interact with Contentstack",
4
- "version": "1.7.5",
4
+ "version": "1.7.7",
5
5
  "author": "Contentstack",
6
6
  "bin": {
7
7
  "csdx": "./bin/run"
8
8
  },
9
9
  "main": "lib/index.js",
10
+ "types": "lib/index.d.ts",
10
11
  "scripts": {
11
12
  "build": "npm run clean && npm run compile",
12
13
  "clean": "rm -rf ./lib ./node_modules tsconfig.build.tsbuildinfo",
@@ -21,22 +22,22 @@
21
22
  "prepack": "pnpm compile && oclif manifest && oclif readme"
22
23
  },
23
24
  "dependencies": {
24
- "@contentstack/cli-auth": "^1.3.7",
25
- "@contentstack/cli-cm-bootstrap": "^1.4.7",
26
- "@contentstack/cli-cm-bulk-publish": "^1.3.6",
27
- "@contentstack/cli-cm-clone": "^1.4.7",
28
- "@contentstack/cli-cm-export": "^1.5.7",
29
- "@contentstack/cli-cm-export-to-csv": "^1.3.7",
30
- "@contentstack/cli-cm-import": "^1.5.7",
31
- "@contentstack/cli-cm-migrate-rte": "^1.4.6",
32
- "@contentstack/cli-cm-seed": "^1.4.7",
33
- "@contentstack/cli-command": "^1.2.7",
34
- "@contentstack/cli-config": "^1.4.5",
35
- "@contentstack/cli-launch": "^1.0.4",
36
- "@contentstack/cli-migration": "^1.3.6",
37
- "@contentstack/cli-utilities": "^1.4.3",
25
+ "@contentstack/cli-auth": "^1.3.9",
26
+ "@contentstack/cli-cm-bootstrap": "^1.4.9",
27
+ "@contentstack/cli-cm-bulk-publish": "^1.3.8",
28
+ "@contentstack/cli-cm-clone": "^1.4.9",
29
+ "@contentstack/cli-cm-export": "^1.5.9",
30
+ "@contentstack/cli-cm-export-to-csv": "^1.3.9",
31
+ "@contentstack/cli-cm-import": "^1.5.9",
32
+ "@contentstack/cli-cm-migrate-rte": "^1.4.8",
33
+ "@contentstack/cli-cm-seed": "^1.4.9",
34
+ "@contentstack/cli-command": "^1.2.9",
35
+ "@contentstack/cli-config": "^1.4.6",
36
+ "@contentstack/cli-launch": "^1.0.6",
37
+ "@contentstack/cli-migration": "^1.3.8",
38
+ "@contentstack/cli-utilities": "^1.4.5",
38
39
  "@contentstack/management": "^1.8.0",
39
- "@contentstack/cli-cm-branches": "^1.0.4",
40
+ "@contentstack/cli-cm-branches": "^1.0.6",
40
41
  "@oclif/plugin-help": "^5",
41
42
  "@oclif/plugin-not-found": "^2.3.9",
42
43
  "@oclif/plugin-plugins": "^2.1.7",
@@ -155,4 +156,4 @@
155
156
  }
156
157
  },
157
158
  "repository": "https://github.com/contentstack/cli"
158
- }
159
+ }