@chabokan.net/cli 0.8.3 → 0.8.5

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 @chabokan.net/cli
18
18
  $ chabok COMMAND
19
19
  running command...
20
20
  $ chabok (--version|-v)
21
- @chabokan.net/cli/0.8.3 darwin-x64 node-v14.17.5
21
+ @chabokan.net/cli/0.8.5 darwin-arm64 node-v18.12.1
22
22
  $ chabok --help [COMMAND]
23
23
  USAGE
24
24
  $ chabok COMMAND
@@ -32,7 +32,7 @@ USAGE
32
32
  * [`chabok account use`](#chabok-account-use)
33
33
  * [`chabok autocomplete [SHELL]`](#chabok-autocomplete-shell)
34
34
  * [`chabok deploy`](#chabok-deploy)
35
- * [`chabok help [COMMAND]`](#chabok-help-command)
35
+ * [`chabok help [COMMANDS]`](#chabok-help-commands)
36
36
  * [`chabok login`](#chabok-login)
37
37
  * [`chabok service list`](#chabok-service-list)
38
38
  * [`chabok service logs`](#chabok-service-logs)
@@ -115,7 +115,7 @@ EXAMPLES
115
115
  $ chabok autocomplete --refresh-cache
116
116
  ```
117
117
 
118
- _See code: [@oclif/plugin-autocomplete](https://github.com/oclif/plugin-autocomplete/blob/v1.3.3/src/commands/autocomplete/index.ts)_
118
+ _See code: [@oclif/plugin-autocomplete](https://github.com/oclif/plugin-autocomplete/blob/v1.4.6/src/commands/autocomplete/index.ts)_
119
119
 
120
120
  ## `chabok deploy`
121
121
 
@@ -134,18 +134,18 @@ DESCRIPTION
134
134
  this command help you build and deploy your service to chabokan in easy way.
135
135
  ```
136
136
 
137
- _See code: [src/commands/deploy.ts](https://github.com/chabokan/cli/blob/v0.8.3/src/commands/deploy.ts)_
137
+ _See code: [src/commands/deploy.ts](https://github.com/chabokan/cli/blob/v0.8.5/src/commands/deploy.ts)_
138
138
 
139
- ## `chabok help [COMMAND]`
139
+ ## `chabok help [COMMANDS]`
140
140
 
141
141
  Display help for chabok.
142
142
 
143
143
  ```
144
144
  USAGE
145
- $ chabok help [COMMAND] [-n]
145
+ $ chabok help [COMMANDS] [-n]
146
146
 
147
147
  ARGUMENTS
148
- COMMAND Command to show help for.
148
+ COMMANDS Command to show help for.
149
149
 
150
150
  FLAGS
151
151
  -n, --nested-commands Include all nested commands in the output.
@@ -154,7 +154,7 @@ DESCRIPTION
154
154
  Display help for chabok.
155
155
  ```
156
156
 
157
- _See code: [@oclif/plugin-help](https://github.com/oclif/plugin-help/blob/v5.1.15/src/commands/help.ts)_
157
+ _See code: [@oclif/plugin-help](https://github.com/oclif/plugin-help/blob/v5.2.10/src/commands/help.ts)_
158
158
 
159
159
  ## `chabok login`
160
160
 
@@ -174,7 +174,7 @@ DESCRIPTION
174
174
  login to hub.chabokan.net account
175
175
  ```
176
176
 
177
- _See code: [src/commands/login.ts](https://github.com/chabokan/cli/blob/v0.8.3/src/commands/login.ts)_
177
+ _See code: [src/commands/login.ts](https://github.com/chabokan/cli/blob/v0.8.5/src/commands/login.ts)_
178
178
 
179
179
  ## `chabok service list`
180
180
 
@@ -292,5 +292,5 @@ FLAG DESCRIPTIONS
292
292
  Additionally shows the architecture, node version, operating system, and versions of plugins that the CLI is using.
293
293
  ```
294
294
 
295
- _See code: [@oclif/plugin-version](https://github.com/oclif/plugin-version/blob/v1.1.3/src/commands/version.ts)_
295
+ _See code: [@oclif/plugin-version](https://github.com/oclif/plugin-version/blob/v1.3.5/src/commands/version.ts)_
296
296
  <!-- commandsstop -->
@@ -73,11 +73,10 @@ class Deploy extends base_1.default {
73
73
  '.next',
74
74
  '.nuxt',
75
75
  '*.*~',
76
- 'liara.json',
77
76
  'node_modules',
78
77
  'bower_components',
79
78
  'venv',
80
- 'vendor',
79
+ '/vendor',
81
80
  '*.log',
82
81
  ];
83
82
  const ignoreCache = {};
@@ -76,6 +76,10 @@ class Login extends base_1.default {
76
76
  cli.log(`${chalk_1.default.green('[Success]')} you are logged in successfully.`);
77
77
  }
78
78
  catch (e) {
79
+ if (process.env.CHABOK_DEBUG == "true") {
80
+ // @ts-ignore
81
+ cli.log(e);
82
+ }
79
83
  cli.log(`${chalk_1.default.red('[Error]')} your token is wrong!`);
80
84
  }
81
85
  }
@@ -1,2 +1,2 @@
1
1
  export declare const GLOBAL_CONF_PATH: string;
2
- export declare const BASE_API_URL = "https://apihub.chabokan.net/fa/api/v1/";
2
+ export declare let BASE_API_URL: string;
package/lib/constants.js CHANGED
@@ -6,3 +6,6 @@ const path = tslib_1.__importStar(require("path"));
6
6
  const os = tslib_1.__importStar(require("os"));
7
7
  exports.GLOBAL_CONF_PATH = path.join(os.homedir(), '.chabok.json');
8
8
  exports.BASE_API_URL = 'https://apihub.chabokan.net/fa/api/v1/';
9
+ if (process.env.CHABOK_API_URL) {
10
+ exports.BASE_API_URL = process.env.CHABOK_API_URL;
11
+ }
@@ -1 +1,312 @@
1
- {"version":"0.8.3","commands":{"deploy":{"id":"deploy","description":"this command help you build and deploy your service to chabokan in easy way.","strict":true,"pluginName":"@chabokan.net/cli","pluginAlias":"@chabokan.net/cli","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false},"path":{"name":"path","type":"option","char":"p","description":"service path in your computer","multiple":false},"service":{"name":"service","type":"option","char":"s","description":"service name","multiple":false}},"args":[]},"login":{"id":"login","description":"login to hub.chabokan.net account","strict":true,"pluginName":"@chabokan.net/cli","pluginAlias":"@chabokan.net/cli","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false},"username":{"name":"username","type":"option","char":"u","description":"your username","multiple":false},"password":{"name":"password","type":"option","char":"p","description":"your password","multiple":false},"token":{"name":"token","type":"option","char":"t","description":"login with api token","multiple":false}},"args":[]},"account:list":{"id":"account:list","description":"show accounts list","strict":true,"pluginName":"@chabokan.net/cli","pluginAlias":"@chabokan.net/cli","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"account:remove":{"id":"account:remove","description":"remove account from list","strict":true,"pluginName":"@chabokan.net/cli","pluginAlias":"@chabokan.net/cli","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"account:use":{"id":"account:use","description":"switch your default user between logged in users","strict":true,"pluginName":"@chabokan.net/cli","pluginAlias":"@chabokan.net/cli","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false},"user":{"name":"user","type":"option","char":"u","description":"default user","multiple":false}},"args":[]},"service:list":{"id":"service:list","description":"show account services list","strict":true,"pluginName":"@chabokan.net/cli","pluginAlias":"@chabokan.net/cli","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"service:logs":{"id":"service:logs","description":"read latest logs from service","strict":true,"pluginName":"@chabokan.net/cli","pluginAlias":"@chabokan.net/cli","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false},"service":{"name":"service","type":"option","char":"s","description":"service name","multiple":false}},"args":[]},"service:resize":{"id":"service:resize","description":"resize a service","strict":true,"pluginName":"@chabokan.net/cli","pluginAlias":"@chabokan.net/cli","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false},"service":{"name":"service","type":"option","char":"s","description":"service name","multiple":false},"ram":{"name":"ram","type":"option","char":"r","description":"RAM","multiple":false},"cpu":{"name":"cpu","type":"option","char":"c","description":"CPU","multiple":false},"disk":{"name":"disk","type":"option","char":"d","description":"DISK","multiple":false}},"args":[]},"service:restart":{"id":"service:restart","description":"restart a service","strict":true,"pluginName":"@chabokan.net/cli","pluginAlias":"@chabokan.net/cli","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false},"service":{"name":"service","type":"option","char":"s","description":"service name","multiple":false}},"args":[]},"service:start":{"id":"service:start","description":"start a service","strict":true,"pluginName":"@chabokan.net/cli","pluginAlias":"@chabokan.net/cli","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false},"service":{"name":"service","type":"option","char":"s","description":"service name","multiple":false}},"args":[]},"service:stop":{"id":"service:stop","description":"stop a service","strict":true,"pluginName":"@chabokan.net/cli","pluginAlias":"@chabokan.net/cli","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false},"service":{"name":"service","type":"option","char":"s","description":"service name","multiple":false}},"args":[]}}}
1
+ {
2
+ "version": "0.8.5",
3
+ "commands": {
4
+ "deploy": {
5
+ "id": "deploy",
6
+ "description": "this command help you build and deploy your service to chabokan in easy way.",
7
+ "strict": true,
8
+ "pluginName": "@chabokan.net/cli",
9
+ "pluginAlias": "@chabokan.net/cli",
10
+ "pluginType": "core",
11
+ "aliases": [],
12
+ "flags": {
13
+ "help": {
14
+ "name": "help",
15
+ "type": "boolean",
16
+ "char": "h",
17
+ "description": "Show CLI help.",
18
+ "allowNo": false
19
+ },
20
+ "path": {
21
+ "name": "path",
22
+ "type": "option",
23
+ "char": "p",
24
+ "description": "service path in your computer",
25
+ "multiple": false
26
+ },
27
+ "service": {
28
+ "name": "service",
29
+ "type": "option",
30
+ "char": "s",
31
+ "description": "service name",
32
+ "multiple": false
33
+ }
34
+ },
35
+ "args": {}
36
+ },
37
+ "login": {
38
+ "id": "login",
39
+ "description": "login to hub.chabokan.net account",
40
+ "strict": true,
41
+ "pluginName": "@chabokan.net/cli",
42
+ "pluginAlias": "@chabokan.net/cli",
43
+ "pluginType": "core",
44
+ "aliases": [],
45
+ "flags": {
46
+ "help": {
47
+ "name": "help",
48
+ "type": "boolean",
49
+ "char": "h",
50
+ "description": "Show CLI help.",
51
+ "allowNo": false
52
+ },
53
+ "username": {
54
+ "name": "username",
55
+ "type": "option",
56
+ "char": "u",
57
+ "description": "your username",
58
+ "multiple": false
59
+ },
60
+ "password": {
61
+ "name": "password",
62
+ "type": "option",
63
+ "char": "p",
64
+ "description": "your password",
65
+ "multiple": false
66
+ },
67
+ "token": {
68
+ "name": "token",
69
+ "type": "option",
70
+ "char": "t",
71
+ "description": "login with api token",
72
+ "multiple": false
73
+ }
74
+ },
75
+ "args": {}
76
+ },
77
+ "account:list": {
78
+ "id": "account:list",
79
+ "description": "show accounts list",
80
+ "strict": true,
81
+ "pluginName": "@chabokan.net/cli",
82
+ "pluginAlias": "@chabokan.net/cli",
83
+ "pluginType": "core",
84
+ "aliases": [],
85
+ "flags": {
86
+ "help": {
87
+ "name": "help",
88
+ "type": "boolean",
89
+ "char": "h",
90
+ "description": "Show CLI help.",
91
+ "allowNo": false
92
+ }
93
+ },
94
+ "args": {}
95
+ },
96
+ "account:remove": {
97
+ "id": "account:remove",
98
+ "description": "remove account from list",
99
+ "strict": true,
100
+ "pluginName": "@chabokan.net/cli",
101
+ "pluginAlias": "@chabokan.net/cli",
102
+ "pluginType": "core",
103
+ "aliases": [],
104
+ "flags": {
105
+ "help": {
106
+ "name": "help",
107
+ "type": "boolean",
108
+ "char": "h",
109
+ "description": "Show CLI help.",
110
+ "allowNo": false
111
+ }
112
+ },
113
+ "args": {}
114
+ },
115
+ "account:use": {
116
+ "id": "account:use",
117
+ "description": "switch your default user between logged in users",
118
+ "strict": true,
119
+ "pluginName": "@chabokan.net/cli",
120
+ "pluginAlias": "@chabokan.net/cli",
121
+ "pluginType": "core",
122
+ "aliases": [],
123
+ "flags": {
124
+ "help": {
125
+ "name": "help",
126
+ "type": "boolean",
127
+ "char": "h",
128
+ "description": "Show CLI help.",
129
+ "allowNo": false
130
+ },
131
+ "user": {
132
+ "name": "user",
133
+ "type": "option",
134
+ "char": "u",
135
+ "description": "default user",
136
+ "multiple": false
137
+ }
138
+ },
139
+ "args": {}
140
+ },
141
+ "service:list": {
142
+ "id": "service:list",
143
+ "description": "show account services list",
144
+ "strict": true,
145
+ "pluginName": "@chabokan.net/cli",
146
+ "pluginAlias": "@chabokan.net/cli",
147
+ "pluginType": "core",
148
+ "aliases": [],
149
+ "flags": {
150
+ "help": {
151
+ "name": "help",
152
+ "type": "boolean",
153
+ "char": "h",
154
+ "description": "Show CLI help.",
155
+ "allowNo": false
156
+ }
157
+ },
158
+ "args": {}
159
+ },
160
+ "service:logs": {
161
+ "id": "service:logs",
162
+ "description": "read latest logs from service",
163
+ "strict": true,
164
+ "pluginName": "@chabokan.net/cli",
165
+ "pluginAlias": "@chabokan.net/cli",
166
+ "pluginType": "core",
167
+ "aliases": [],
168
+ "flags": {
169
+ "help": {
170
+ "name": "help",
171
+ "type": "boolean",
172
+ "char": "h",
173
+ "description": "Show CLI help.",
174
+ "allowNo": false
175
+ },
176
+ "service": {
177
+ "name": "service",
178
+ "type": "option",
179
+ "char": "s",
180
+ "description": "service name",
181
+ "multiple": false
182
+ }
183
+ },
184
+ "args": {}
185
+ },
186
+ "service:resize": {
187
+ "id": "service:resize",
188
+ "description": "resize a service",
189
+ "strict": true,
190
+ "pluginName": "@chabokan.net/cli",
191
+ "pluginAlias": "@chabokan.net/cli",
192
+ "pluginType": "core",
193
+ "aliases": [],
194
+ "flags": {
195
+ "help": {
196
+ "name": "help",
197
+ "type": "boolean",
198
+ "char": "h",
199
+ "description": "Show CLI help.",
200
+ "allowNo": false
201
+ },
202
+ "service": {
203
+ "name": "service",
204
+ "type": "option",
205
+ "char": "s",
206
+ "description": "service name",
207
+ "multiple": false
208
+ },
209
+ "ram": {
210
+ "name": "ram",
211
+ "type": "option",
212
+ "char": "r",
213
+ "description": "RAM",
214
+ "multiple": false
215
+ },
216
+ "cpu": {
217
+ "name": "cpu",
218
+ "type": "option",
219
+ "char": "c",
220
+ "description": "CPU",
221
+ "multiple": false
222
+ },
223
+ "disk": {
224
+ "name": "disk",
225
+ "type": "option",
226
+ "char": "d",
227
+ "description": "DISK",
228
+ "multiple": false
229
+ }
230
+ },
231
+ "args": {}
232
+ },
233
+ "service:restart": {
234
+ "id": "service:restart",
235
+ "description": "restart a service",
236
+ "strict": true,
237
+ "pluginName": "@chabokan.net/cli",
238
+ "pluginAlias": "@chabokan.net/cli",
239
+ "pluginType": "core",
240
+ "aliases": [],
241
+ "flags": {
242
+ "help": {
243
+ "name": "help",
244
+ "type": "boolean",
245
+ "char": "h",
246
+ "description": "Show CLI help.",
247
+ "allowNo": false
248
+ },
249
+ "service": {
250
+ "name": "service",
251
+ "type": "option",
252
+ "char": "s",
253
+ "description": "service name",
254
+ "multiple": false
255
+ }
256
+ },
257
+ "args": {}
258
+ },
259
+ "service:start": {
260
+ "id": "service:start",
261
+ "description": "start a service",
262
+ "strict": true,
263
+ "pluginName": "@chabokan.net/cli",
264
+ "pluginAlias": "@chabokan.net/cli",
265
+ "pluginType": "core",
266
+ "aliases": [],
267
+ "flags": {
268
+ "help": {
269
+ "name": "help",
270
+ "type": "boolean",
271
+ "char": "h",
272
+ "description": "Show CLI help.",
273
+ "allowNo": false
274
+ },
275
+ "service": {
276
+ "name": "service",
277
+ "type": "option",
278
+ "char": "s",
279
+ "description": "service name",
280
+ "multiple": false
281
+ }
282
+ },
283
+ "args": {}
284
+ },
285
+ "service:stop": {
286
+ "id": "service:stop",
287
+ "description": "stop a service",
288
+ "strict": true,
289
+ "pluginName": "@chabokan.net/cli",
290
+ "pluginAlias": "@chabokan.net/cli",
291
+ "pluginType": "core",
292
+ "aliases": [],
293
+ "flags": {
294
+ "help": {
295
+ "name": "help",
296
+ "type": "boolean",
297
+ "char": "h",
298
+ "description": "Show CLI help.",
299
+ "allowNo": false
300
+ },
301
+ "service": {
302
+ "name": "service",
303
+ "type": "option",
304
+ "char": "s",
305
+ "description": "service name",
306
+ "multiple": false
307
+ }
308
+ },
309
+ "args": {}
310
+ }
311
+ }
312
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chabokan.net/cli",
3
- "version": "0.8.3",
3
+ "version": "0.8.5",
4
4
  "description": "Chabokan Cli for PaaS Services",
5
5
  "author": "Mohammad Abdi",
6
6
  "bin": {
@@ -93,7 +93,7 @@
93
93
  "version": "oclif readme && git add README.md"
94
94
  },
95
95
  "engines": {
96
- "node": ">=14.0.0"
96
+ "node": ">=16.0.0"
97
97
  },
98
98
  "bugs": "https://github.com/chabokan/cli/issues",
99
99
  "keywords": [