Skip to content

Commit 03ce7d9

Browse files
author
Aamod Pisat
committed
hotfix 3.0.2
1 parent 8b6f298 commit 03ce7d9

File tree

6 files changed

+363
-154
lines changed

6 files changed

+363
-154
lines changed

README.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,12 @@
33
# Built.io Contentstack Command Line Interface(CLI).
44

55
## Installation
6-
7-
**Note: Built.io Contentstack CLI version 1.x can be used only for contentstack-express version 1.x.**
6+
**Note: This version of Built.io Contentstack CLI can be used only for V3 stacks. Use CLI version 1.x, for V2 stacks.**
87

98
Run the following command in a Terminal or Command Prompt to globally install the latest version of Built.io Contentstack CLI on your system:
109

1110
```bash
12-
$ npm install -g contentstack-cli@1.x
11+
$ npm install -g contentstack-cli
1312
```
1413
*You might need administrator privileges to perform this installation.*
1514

@@ -29,8 +28,10 @@ Built.io Contentstack CLI comes with handy commands which helps to achieve the s
2928
****
3029
***
3130
**
31+
32+
Note: This version of Built.io Contentstack CLI can be used only for V3 stacks. Use CLI version 1.x, for V2 stacks.
3233
33-
Built.io Contentstack Command Line Interface 1.0.5
34+
Built.io Contentstack Command Line Interface 3.0.0
3435
3536
Usage: contentstack [command]
3637
@@ -92,7 +93,7 @@ Once the plugin is created, you can activate it in config/all.js file.
9293

9394
## Links
9495
- [Website](https://www.built.io/products/contentstack/overview)
95-
- [Official Documentation](http://contentstackdocs.built.io/developer/javascript/quickstart)
96+
- [Official Documentation](https://contentstackdocs.built.io/developer/web/framework-cli)
9697

9798
### License
98-
Copyright © 2012-2016 [Built.io](https://www.built.io/). All Rights Reserved.
99+
Copyright © 2012-2017 [Built.io](https://www.built.io/). All Rights Reserved.

bin/index.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ function optionConversion(options) {
7474
}
7575
// printing the Built.io Contentstack Animation
7676
console.log('\n'+messages+'\x1b[0m\n');
77-
console.log('\x1b[31m Note: Built.io Contentstack CLI version 1.x can be used only for contentstack-express version 1.x.\x1b[0m\n');
77+
console.log('\x1b[31m Note: This version of Built.io Contentstack CLI can be used only for V3 stacks. Use CLI version 1.x, for V2 stacks.\x1b[0m\n');
7878

7979
program
8080
.version(pkg.version || "0.1.x");
@@ -130,6 +130,7 @@ program
130130
program
131131
.command('sync')
132132
.option('-e, --env <environment>', 'Enter the environment of which the content needs to be synchronized', undefined)
133+
.option('-t, --type [type]', 'Enter a type of content to include in publishing [content_types/assets/all]', /(content_types|assets|all)/, undefined)
133134
.option('-l, --lang [language]', 'Enter the language of which the content needs to be synchronized', undefined)
134135
.option('-c, --content_types [content_types]', 'Enter the content types to be included in synchronization (comma(",") seperated)', list, undefined)
135136
.option('-s, --skip_content_types [skip_content_types]', 'Enter the content types to be excluded from synchronization (comma(",") seperated)', list, undefined)
@@ -235,7 +236,7 @@ if (program.args.length == 0) {
235236
, '\nOptions:'
236237
, ' -h, --help output usage information'
237238
, ' -V, --version output the version number'
238-
, '\nDocumentation can be found at http://contentstackdocs.built.io/'
239+
, '\nDocumentation can be found at https://contentstackdocs.built.io/'
239240
].join('\n');
240241
console.log(message);
241242
process.exit(1);

lib/helper.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ exports.confirm = function(config, lang, backup, callback) {
9090
}
9191
} catch (e) {
9292
console.error("Error in Confirm : ", e.message);
93-
callback(e);
93+
callback(e.message);
9494
}
9595
};
9696

lib/plugin.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,9 @@ var prompt = require('prompt'),
2020
/*
2121
* Application
2222
* */
23-
var helper = require('./helper');
23+
var helper = require('./helper'),
24+
utility = require('./utils'),
25+
utility = new utility();
2426

2527
var Plugin = function (name) {
2628
try {
@@ -141,7 +143,7 @@ var pluginTemplate = function (_name, pluginName) {
141143
' /*',
142144
' * @beforePublish',
143145
' * @Description: This function is triggered when the publish event occurs.',
144-
' * @Parameters: data - contains published asset, entry, it\'s content_type and language.',
146+
' * @Parameters: data - contains un-published entry, it\'s content_type and language.',
145147
' * @Parameters: next - call this function to pass control to the next subsequent "beforePublish" hook.',
146148
' * It is important to call the next() function, it will affect the publish process,',
147149
' * the entry will get stuck to "in-prgoress" state.',
@@ -161,7 +163,7 @@ var pluginTemplate = function (_name, pluginName) {
161163
' /*',
162164
' * @beforeUnpublish',
163165
' * @Description: This function is triggered when the unpublish or delete event occurs.',
164-
' * @Parameters: data - contains un-published asset, entry, it\'s content_type and language.',
166+
' * @Parameters: data - contains un-published entry, it\'s content_type and language.',
165167
' * @Parameters: next - call this function to pass control to the next subsequent "beforeUnpublish" hook.',
166168
' * It is important to call the next() function, it will affect the unpublish process,',
167169
' * the entry will get stuck to "in-prgoress" state.',

0 commit comments

Comments
 (0)