swaggerhub-cli 0.9.0 → 0.9.1
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 +167 -123
- package/oclif.manifest.json +1 -1
- package/package.json +13 -12
- package/src/config/index.js +3 -2
package/README.md
CHANGED
|
@@ -16,7 +16,7 @@ The SwaggerHub CLI enables teams to build automation and workflows around Swagge
|
|
|
16
16
|
* [Contributing](#contributing)
|
|
17
17
|
<!-- tocstop -->
|
|
18
18
|
# Requirements
|
|
19
|
-
Node.js
|
|
19
|
+
Node.js 18.x or later.
|
|
20
20
|
|
|
21
21
|
# Installation
|
|
22
22
|
```sh-session
|
|
@@ -120,7 +120,7 @@ USAGE
|
|
|
120
120
|
* [`swaggerhub domain:setdefault OWNER/DOMAIN_NAME/VERSION`](#swaggerhub-domainsetdefault)
|
|
121
121
|
* [`swaggerhub domain:unpublish OWNER/DOMAIN_NAME/VERSION`](#swaggerhub-domainunpublish)
|
|
122
122
|
* [`swaggerhub domain:update OWNER/DOMAIN_NAME/[VERSION]`](#swaggerhub-domainupdate)
|
|
123
|
-
* [`swaggerhub help [
|
|
123
|
+
* [`swaggerhub help [COMMAND]`](#swaggerhub-help)
|
|
124
124
|
* [`swaggerhub integration:create OWNER/API_NAME/[VERSION]`](#swaggerhub-integrationcreate)
|
|
125
125
|
* [`swaggerhub integration:delete OWNER/API_NAME/VERSION/INTEGRATION_ID`](#swaggerhub-integrationdelete)
|
|
126
126
|
* [`swaggerhub integration:execute OWNER/API_NAME/VERSION/INTEGRATION_ID`](#swaggerhub-integrationexecute)
|
|
@@ -128,13 +128,14 @@ USAGE
|
|
|
128
128
|
* [`swaggerhub integration:list OWNER/API_NAME/[VERSION]`](#swaggerhub-integrationlist)
|
|
129
129
|
* [`swaggerhub integration:update OWNER/API_NAME/VERSION/INTEGRATION_ID`](#swaggerhub-integrationupdate)
|
|
130
130
|
* [`swaggerhub plugins`](#swaggerhub-plugins)
|
|
131
|
-
* [`swaggerhub plugins:
|
|
131
|
+
* [`swaggerhub plugins:add PLUGIN`](#swaggerhub-pluginsadd)
|
|
132
132
|
* [`swaggerhub plugins:inspect PLUGIN...`](#swaggerhub-pluginsinspect)
|
|
133
|
-
* [`swaggerhub plugins:install PLUGIN
|
|
134
|
-
* [`swaggerhub plugins:link
|
|
135
|
-
* [`swaggerhub plugins:
|
|
136
|
-
* [`swaggerhub plugins:
|
|
137
|
-
* [`swaggerhub plugins:uninstall PLUGIN
|
|
133
|
+
* [`swaggerhub plugins:install PLUGIN`](#swaggerhub-pluginsinstall)
|
|
134
|
+
* [`swaggerhub plugins:link PATH`](#swaggerhub-pluginslink)
|
|
135
|
+
* [`swaggerhub plugins:remove [PLUGIN]`](#swaggerhub-pluginsremove)
|
|
136
|
+
* [`swaggerhub plugins:reset`](#swaggerhub-pluginsreset)
|
|
137
|
+
* [`swaggerhub plugins:uninstall [PLUGIN]`](#swaggerhub-pluginsuninstall)
|
|
138
|
+
* [`swaggerhub plugins:unlink [PLUGIN]`](#swaggerhub-pluginsunlink)
|
|
138
139
|
* [`swaggerhub plugins:update`](#swaggerhub-pluginsupdate)
|
|
139
140
|
* [`swaggerhub project:api:add OWNER/PROJECT_NAME API`](#swaggerhub-projectapiadd)
|
|
140
141
|
* [`swaggerhub project:api:remove OWNER/PROJECT_NAME API`](#swaggerhub-projectapiremove)
|
|
@@ -159,13 +160,13 @@ ARGUMENTS
|
|
|
159
160
|
OWNER/API_NAME/[VERSION] API to create on SwaggerHub
|
|
160
161
|
|
|
161
162
|
FLAGS
|
|
162
|
-
-f, --file=<value>
|
|
163
|
-
-h, --help
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
163
|
+
-f, --file=<value> (required) file location of API to create
|
|
164
|
+
-h, --help Show CLI help.
|
|
165
|
+
--published=<option> [default: unpublish] sets the lifecycle setting of the API version
|
|
166
|
+
<options: publish|unpublish>
|
|
167
|
+
--setdefault sets API version to be the default
|
|
168
|
+
--visibility=<option> [default: private] visibility of API in SwaggerHub
|
|
169
|
+
<options: public|private>
|
|
169
170
|
|
|
170
171
|
DESCRIPTION
|
|
171
172
|
creates a new API / API version from a YAML/JSON file
|
|
@@ -185,7 +186,7 @@ EXAMPLES
|
|
|
185
186
|
$ swaggerhub api:create organization/api/1.0.0 --published=publish --setdefault --file api.json
|
|
186
187
|
```
|
|
187
188
|
|
|
188
|
-
_See code: [src/commands/api/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
189
|
+
_See code: [src/commands/api/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/api/create.js)_
|
|
189
190
|
|
|
190
191
|
## `swaggerhub api:delete`
|
|
191
192
|
|
|
@@ -214,7 +215,7 @@ EXAMPLES
|
|
|
214
215
|
$ swaggerhub api:delete organization/api --force
|
|
215
216
|
```
|
|
216
217
|
|
|
217
|
-
_See code: [src/commands/api/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
218
|
+
_See code: [src/commands/api/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/api/delete.js)_
|
|
218
219
|
|
|
219
220
|
## `swaggerhub api:get`
|
|
220
221
|
|
|
@@ -244,7 +245,7 @@ EXAMPLES
|
|
|
244
245
|
$ swaggerhub api:get organization/api/1.0.0 --json
|
|
245
246
|
```
|
|
246
247
|
|
|
247
|
-
_See code: [src/commands/api/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
248
|
+
_See code: [src/commands/api/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/api/get.js)_
|
|
248
249
|
|
|
249
250
|
## `swaggerhub api:publish`
|
|
250
251
|
|
|
@@ -270,7 +271,7 @@ EXAMPLES
|
|
|
270
271
|
$ swaggerhub api:publish organization/api/1.0.0 --force
|
|
271
272
|
```
|
|
272
273
|
|
|
273
|
-
_See code: [src/commands/api/publish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
274
|
+
_See code: [src/commands/api/publish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/api/publish.js)_
|
|
274
275
|
|
|
275
276
|
## `swaggerhub api:setdefault`
|
|
276
277
|
|
|
@@ -293,7 +294,7 @@ EXAMPLES
|
|
|
293
294
|
$ swaggerhub api:setdefault organization/api/2.0.0
|
|
294
295
|
```
|
|
295
296
|
|
|
296
|
-
_See code: [src/commands/api/setdefault.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
297
|
+
_See code: [src/commands/api/setdefault.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/api/setdefault.js)_
|
|
297
298
|
|
|
298
299
|
## `swaggerhub api:unpublish`
|
|
299
300
|
|
|
@@ -316,7 +317,7 @@ EXAMPLES
|
|
|
316
317
|
$ swaggerhub api:unpublish organization/api/1.0.0
|
|
317
318
|
```
|
|
318
319
|
|
|
319
|
-
_See code: [src/commands/api/unpublish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
320
|
+
_See code: [src/commands/api/unpublish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/api/unpublish.js)_
|
|
320
321
|
|
|
321
322
|
## `swaggerhub api:update`
|
|
322
323
|
|
|
@@ -331,13 +332,13 @@ ARGUMENTS
|
|
|
331
332
|
OWNER/API_NAME/[VERSION] API to update on SwaggerHub
|
|
332
333
|
|
|
333
334
|
FLAGS
|
|
334
|
-
-f, --file=<value>
|
|
335
|
-
-h, --help
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
335
|
+
-f, --file=<value> file location of API to update
|
|
336
|
+
-h, --help Show CLI help.
|
|
337
|
+
--published=<option> sets the lifecycle setting of the API version
|
|
338
|
+
<options: publish|unpublish>
|
|
339
|
+
--setdefault sets API version to be the default
|
|
340
|
+
--visibility=<option> visibility of API in SwaggerHub
|
|
341
|
+
<options: public|private>
|
|
341
342
|
|
|
342
343
|
DESCRIPTION
|
|
343
344
|
update an API
|
|
@@ -360,7 +361,7 @@ EXAMPLES
|
|
|
360
361
|
$ swaggerhub api:update organization/api/1.0.0 --visibility=private
|
|
361
362
|
```
|
|
362
363
|
|
|
363
|
-
_See code: [src/commands/api/update.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
364
|
+
_See code: [src/commands/api/update.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/api/update.js)_
|
|
364
365
|
|
|
365
366
|
## `swaggerhub api:validate`
|
|
366
367
|
|
|
@@ -394,7 +395,7 @@ EXAMPLES
|
|
|
394
395
|
$ swaggerhub api:validate --fail-on-critical --json organization/api
|
|
395
396
|
```
|
|
396
397
|
|
|
397
|
-
_See code: [src/commands/api/validate/index.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
398
|
+
_See code: [src/commands/api/validate/index.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/api/validate/index.js)_
|
|
398
399
|
|
|
399
400
|
## `swaggerhub api:validate:download-rules`
|
|
400
401
|
|
|
@@ -425,7 +426,7 @@ EXAMPLES
|
|
|
425
426
|
$ swaggerhub api:validate:download-rules myOrg --include-disabled-rules -s
|
|
426
427
|
```
|
|
427
428
|
|
|
428
|
-
_See code: [src/commands/api/validate/download-rules.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
429
|
+
_See code: [src/commands/api/validate/download-rules.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/api/validate/download-rules.js)_
|
|
429
430
|
|
|
430
431
|
## `swaggerhub api:validate:local`
|
|
431
432
|
|
|
@@ -455,7 +456,7 @@ EXAMPLES
|
|
|
455
456
|
$ swaggerhub api:validate:local --organization myOrg --file ./my-api/json --fail-on-critical --json
|
|
456
457
|
```
|
|
457
458
|
|
|
458
|
-
_See code: [src/commands/api/validate/local.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
459
|
+
_See code: [src/commands/api/validate/local.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/api/validate/local.js)_
|
|
459
460
|
|
|
460
461
|
## `swaggerhub configure`
|
|
461
462
|
|
|
@@ -478,7 +479,7 @@ DESCRIPTION
|
|
|
478
479
|
settings.
|
|
479
480
|
```
|
|
480
481
|
|
|
481
|
-
_See code: [src/commands/configure.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
482
|
+
_See code: [src/commands/configure.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/configure.js)_
|
|
482
483
|
|
|
483
484
|
## `swaggerhub domain:create`
|
|
484
485
|
|
|
@@ -493,13 +494,13 @@ ARGUMENTS
|
|
|
493
494
|
OWNER/DOMAIN_NAME/[VERSION] Domain to create on SwaggerHub
|
|
494
495
|
|
|
495
496
|
FLAGS
|
|
496
|
-
-f, --file=<value>
|
|
497
|
-
-h, --help
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
497
|
+
-f, --file=<value> (required) file location of domain to create
|
|
498
|
+
-h, --help Show CLI help.
|
|
499
|
+
--published=<option> [default: unpublish] sets the lifecycle setting of the domain version
|
|
500
|
+
<options: publish|unpublish>
|
|
501
|
+
--setdefault sets domain version to be the default
|
|
502
|
+
--visibility=<option> [default: private] visibility of domain in SwaggerHub
|
|
503
|
+
<options: public|private>
|
|
503
504
|
|
|
504
505
|
DESCRIPTION
|
|
505
506
|
creates a new domain / domain version from a YAML/JSON file
|
|
@@ -519,7 +520,7 @@ EXAMPLES
|
|
|
519
520
|
$ swaggerhub domain:create organization/domain/1.0.0 --publish --setdefault --file domain.json
|
|
520
521
|
```
|
|
521
522
|
|
|
522
|
-
_See code: [src/commands/domain/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
523
|
+
_See code: [src/commands/domain/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/domain/create.js)_
|
|
523
524
|
|
|
524
525
|
## `swaggerhub domain:delete`
|
|
525
526
|
|
|
@@ -548,7 +549,7 @@ EXAMPLES
|
|
|
548
549
|
$ swaggerhub domain:delete organization/domain --force
|
|
549
550
|
```
|
|
550
551
|
|
|
551
|
-
_See code: [src/commands/domain/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
552
|
+
_See code: [src/commands/domain/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/domain/delete.js)_
|
|
552
553
|
|
|
553
554
|
## `swaggerhub domain:get`
|
|
554
555
|
|
|
@@ -577,7 +578,7 @@ EXAMPLES
|
|
|
577
578
|
$ swaggerhub domain:get organization/domain/1.0.0 --json
|
|
578
579
|
```
|
|
579
580
|
|
|
580
|
-
_See code: [src/commands/domain/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
581
|
+
_See code: [src/commands/domain/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/domain/get.js)_
|
|
581
582
|
|
|
582
583
|
## `swaggerhub domain:publish`
|
|
583
584
|
|
|
@@ -600,7 +601,7 @@ EXAMPLES
|
|
|
600
601
|
$ swaggerhub domain:publish organization/domain/1.0.0
|
|
601
602
|
```
|
|
602
603
|
|
|
603
|
-
_See code: [src/commands/domain/publish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
604
|
+
_See code: [src/commands/domain/publish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/domain/publish.js)_
|
|
604
605
|
|
|
605
606
|
## `swaggerhub domain:setdefault`
|
|
606
607
|
|
|
@@ -623,7 +624,7 @@ EXAMPLES
|
|
|
623
624
|
$ swaggerhub domain:setdefault organization/domain/2.0.0
|
|
624
625
|
```
|
|
625
626
|
|
|
626
|
-
_See code: [src/commands/domain/setdefault.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
627
|
+
_See code: [src/commands/domain/setdefault.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/domain/setdefault.js)_
|
|
627
628
|
|
|
628
629
|
## `swaggerhub domain:unpublish`
|
|
629
630
|
|
|
@@ -646,7 +647,7 @@ EXAMPLES
|
|
|
646
647
|
$ swaggerhub domain:unpublish organization/domain/1.0.0
|
|
647
648
|
```
|
|
648
649
|
|
|
649
|
-
_See code: [src/commands/domain/unpublish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
650
|
+
_See code: [src/commands/domain/unpublish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/domain/unpublish.js)_
|
|
650
651
|
|
|
651
652
|
## `swaggerhub domain:update`
|
|
652
653
|
|
|
@@ -661,13 +662,13 @@ ARGUMENTS
|
|
|
661
662
|
OWNER/DOMAIN_NAME/[VERSION] Domain to update on SwaggerHub
|
|
662
663
|
|
|
663
664
|
FLAGS
|
|
664
|
-
-f, --file=<value>
|
|
665
|
-
-h, --help
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
665
|
+
-f, --file=<value> file location of domain to update
|
|
666
|
+
-h, --help Show CLI help.
|
|
667
|
+
--published=<option> sets the lifecycle setting of the domain version
|
|
668
|
+
<options: publish|unpublish>
|
|
669
|
+
--setdefault sets domain version to be the default
|
|
670
|
+
--visibility=<option> visibility of domain in SwaggerHub
|
|
671
|
+
<options: public|private>
|
|
671
672
|
|
|
672
673
|
DESCRIPTION
|
|
673
674
|
update a domain
|
|
@@ -690,7 +691,7 @@ EXAMPLES
|
|
|
690
691
|
$ swaggerhub domain:update organization/domain/1.0.0 --visibility=private
|
|
691
692
|
```
|
|
692
693
|
|
|
693
|
-
_See code: [src/commands/domain/update.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
694
|
+
_See code: [src/commands/domain/update.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/domain/update.js)_
|
|
694
695
|
|
|
695
696
|
## `swaggerhub help`
|
|
696
697
|
|
|
@@ -698,10 +699,10 @@ Display help for swaggerhub.
|
|
|
698
699
|
|
|
699
700
|
```
|
|
700
701
|
USAGE
|
|
701
|
-
$ swaggerhub help [
|
|
702
|
+
$ swaggerhub help [COMMAND...] [-n]
|
|
702
703
|
|
|
703
704
|
ARGUMENTS
|
|
704
|
-
|
|
705
|
+
COMMAND... Command to show help for.
|
|
705
706
|
|
|
706
707
|
FLAGS
|
|
707
708
|
-n, --nested-commands Include all nested commands in the output.
|
|
@@ -710,7 +711,7 @@ DESCRIPTION
|
|
|
710
711
|
Display help for swaggerhub.
|
|
711
712
|
```
|
|
712
713
|
|
|
713
|
-
_See code: [@oclif/plugin-help](https://github.com/oclif/plugin-help/blob/v6.0.
|
|
714
|
+
_See code: [@oclif/plugin-help](https://github.com/oclif/plugin-help/blob/v6.0.22/src/commands/help.ts)_
|
|
714
715
|
|
|
715
716
|
## `swaggerhub integration:create`
|
|
716
717
|
|
|
@@ -738,7 +739,7 @@ EXAMPLES
|
|
|
738
739
|
$ swaggerhub integration:create organization/api/1.0.0 --file config.json
|
|
739
740
|
```
|
|
740
741
|
|
|
741
|
-
_See code: [src/commands/integration/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
742
|
+
_See code: [src/commands/integration/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/integration/create.js)_
|
|
742
743
|
|
|
743
744
|
## `swaggerhub integration:delete`
|
|
744
745
|
|
|
@@ -761,7 +762,7 @@ EXAMPLES
|
|
|
761
762
|
$ swaggerhub integration:delete organization/api/1.0.0/503c2db6-448a-4678-a310-f465429e9704
|
|
762
763
|
```
|
|
763
764
|
|
|
764
|
-
_See code: [src/commands/integration/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
765
|
+
_See code: [src/commands/integration/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/integration/delete.js)_
|
|
765
766
|
|
|
766
767
|
## `swaggerhub integration:execute`
|
|
767
768
|
|
|
@@ -784,7 +785,7 @@ EXAMPLES
|
|
|
784
785
|
$ swaggerhub integration:execute organization/api/1.0.0/503c2db6-448a-4678-a310-f465429e9704
|
|
785
786
|
```
|
|
786
787
|
|
|
787
|
-
_See code: [src/commands/integration/execute.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
788
|
+
_See code: [src/commands/integration/execute.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/integration/execute.js)_
|
|
788
789
|
|
|
789
790
|
## `swaggerhub integration:get`
|
|
790
791
|
|
|
@@ -807,7 +808,7 @@ EXAMPLES
|
|
|
807
808
|
$ swaggerhub integration:get organization/api/1.0.0/503c2db6-448a-4678-a310-f465429e9704
|
|
808
809
|
```
|
|
809
810
|
|
|
810
|
-
_See code: [src/commands/integration/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
811
|
+
_See code: [src/commands/integration/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/integration/get.js)_
|
|
811
812
|
|
|
812
813
|
## `swaggerhub integration:list`
|
|
813
814
|
|
|
@@ -830,7 +831,7 @@ EXAMPLES
|
|
|
830
831
|
$ swaggerhub integration:list organization/api/1.0.0
|
|
831
832
|
```
|
|
832
833
|
|
|
833
|
-
_See code: [src/commands/integration/list.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
834
|
+
_See code: [src/commands/integration/list.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/integration/list.js)_
|
|
834
835
|
|
|
835
836
|
## `swaggerhub integration:update`
|
|
836
837
|
|
|
@@ -854,7 +855,7 @@ EXAMPLES
|
|
|
854
855
|
$ swaggerhub integration:update organization/api/1.0.0/503c2db6-448a-4678-abcd-0123456789abc --file config.json
|
|
855
856
|
```
|
|
856
857
|
|
|
857
|
-
_See code: [src/commands/integration/update.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
858
|
+
_See code: [src/commands/integration/update.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/integration/update.js)_
|
|
858
859
|
|
|
859
860
|
## `swaggerhub plugins`
|
|
860
861
|
|
|
@@ -877,44 +878,53 @@ EXAMPLES
|
|
|
877
878
|
$ swaggerhub plugins
|
|
878
879
|
```
|
|
879
880
|
|
|
880
|
-
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/
|
|
881
|
+
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.4.25/src/commands/plugins/index.ts)_
|
|
881
882
|
|
|
882
|
-
## `swaggerhub plugins:
|
|
883
|
+
## `swaggerhub plugins:add`
|
|
883
884
|
|
|
884
|
-
Installs a plugin into
|
|
885
|
+
Installs a plugin into swaggerhub.
|
|
885
886
|
|
|
886
887
|
```
|
|
887
888
|
USAGE
|
|
888
|
-
$ swaggerhub plugins:
|
|
889
|
+
$ swaggerhub plugins:add PLUGIN... [--json] [-f] [-h] [-s | -v]
|
|
889
890
|
|
|
890
891
|
ARGUMENTS
|
|
891
|
-
PLUGIN Plugin to install.
|
|
892
|
+
PLUGIN... Plugin to install.
|
|
892
893
|
|
|
893
894
|
FLAGS
|
|
894
|
-
-f, --force
|
|
895
|
+
-f, --force Force npm to fetch remote resources even if a local copy exists on disk.
|
|
895
896
|
-h, --help Show CLI help.
|
|
896
|
-
-
|
|
897
|
+
-s, --silent Silences npm output.
|
|
898
|
+
-v, --verbose Show verbose npm output.
|
|
899
|
+
|
|
900
|
+
GLOBAL FLAGS
|
|
901
|
+
--json Format output as json.
|
|
897
902
|
|
|
898
903
|
DESCRIPTION
|
|
899
|
-
Installs a plugin into
|
|
900
|
-
Can be installed from npm or a git url.
|
|
904
|
+
Installs a plugin into swaggerhub.
|
|
901
905
|
|
|
902
|
-
|
|
906
|
+
Uses npm to install plugins.
|
|
903
907
|
|
|
904
|
-
|
|
905
|
-
will override the core plugin implementation. This is useful if a user needs to update core plugin functionality in
|
|
906
|
-
the CLI without the need to patch and update the whole CLI.
|
|
908
|
+
Installation of a user-installed plugin will override a core plugin.
|
|
907
909
|
|
|
910
|
+
Use the SWAGGERHUB_NPM_LOG_LEVEL environment variable to set the npm loglevel.
|
|
911
|
+
Use the SWAGGERHUB_NPM_REGISTRY environment variable to set the npm registry.
|
|
908
912
|
|
|
909
913
|
ALIASES
|
|
910
914
|
$ swaggerhub plugins:add
|
|
911
915
|
|
|
912
916
|
EXAMPLES
|
|
913
|
-
|
|
917
|
+
Install a plugin from npm registry.
|
|
918
|
+
|
|
919
|
+
$ swaggerhub plugins:add myplugin
|
|
920
|
+
|
|
921
|
+
Install a plugin from a github url.
|
|
922
|
+
|
|
923
|
+
$ swaggerhub plugins:add https://github.com/someuser/someplugin
|
|
914
924
|
|
|
915
|
-
|
|
925
|
+
Install a plugin from a github slug.
|
|
916
926
|
|
|
917
|
-
|
|
927
|
+
$ swaggerhub plugins:add someuser/someplugin
|
|
918
928
|
```
|
|
919
929
|
|
|
920
930
|
## `swaggerhub plugins:inspect`
|
|
@@ -926,7 +936,7 @@ USAGE
|
|
|
926
936
|
$ swaggerhub plugins:inspect PLUGIN...
|
|
927
937
|
|
|
928
938
|
ARGUMENTS
|
|
929
|
-
PLUGIN [default: .] Plugin to inspect.
|
|
939
|
+
PLUGIN... [default: .] Plugin to inspect.
|
|
930
940
|
|
|
931
941
|
FLAGS
|
|
932
942
|
-h, --help Show CLI help.
|
|
@@ -942,47 +952,56 @@ EXAMPLES
|
|
|
942
952
|
$ swaggerhub plugins:inspect myplugin
|
|
943
953
|
```
|
|
944
954
|
|
|
945
|
-
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/
|
|
955
|
+
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.4.25/src/commands/plugins/inspect.ts)_
|
|
946
956
|
|
|
947
957
|
## `swaggerhub plugins:install`
|
|
948
958
|
|
|
949
|
-
Installs a plugin into
|
|
959
|
+
Installs a plugin into swaggerhub.
|
|
950
960
|
|
|
951
961
|
```
|
|
952
962
|
USAGE
|
|
953
|
-
$ swaggerhub plugins:install PLUGIN...
|
|
963
|
+
$ swaggerhub plugins:install PLUGIN... [--json] [-f] [-h] [-s | -v]
|
|
954
964
|
|
|
955
965
|
ARGUMENTS
|
|
956
|
-
PLUGIN Plugin to install.
|
|
966
|
+
PLUGIN... Plugin to install.
|
|
957
967
|
|
|
958
968
|
FLAGS
|
|
959
|
-
-f, --force
|
|
969
|
+
-f, --force Force npm to fetch remote resources even if a local copy exists on disk.
|
|
960
970
|
-h, --help Show CLI help.
|
|
961
|
-
-
|
|
971
|
+
-s, --silent Silences npm output.
|
|
972
|
+
-v, --verbose Show verbose npm output.
|
|
973
|
+
|
|
974
|
+
GLOBAL FLAGS
|
|
975
|
+
--json Format output as json.
|
|
962
976
|
|
|
963
977
|
DESCRIPTION
|
|
964
|
-
Installs a plugin into
|
|
965
|
-
Can be installed from npm or a git url.
|
|
978
|
+
Installs a plugin into swaggerhub.
|
|
966
979
|
|
|
967
|
-
|
|
980
|
+
Uses npm to install plugins.
|
|
968
981
|
|
|
969
|
-
|
|
970
|
-
will override the core plugin implementation. This is useful if a user needs to update core plugin functionality in
|
|
971
|
-
the CLI without the need to patch and update the whole CLI.
|
|
982
|
+
Installation of a user-installed plugin will override a core plugin.
|
|
972
983
|
|
|
984
|
+
Use the SWAGGERHUB_NPM_LOG_LEVEL environment variable to set the npm loglevel.
|
|
985
|
+
Use the SWAGGERHUB_NPM_REGISTRY environment variable to set the npm registry.
|
|
973
986
|
|
|
974
987
|
ALIASES
|
|
975
988
|
$ swaggerhub plugins:add
|
|
976
989
|
|
|
977
990
|
EXAMPLES
|
|
978
|
-
|
|
991
|
+
Install a plugin from npm registry.
|
|
992
|
+
|
|
993
|
+
$ swaggerhub plugins:install myplugin
|
|
994
|
+
|
|
995
|
+
Install a plugin from a github url.
|
|
979
996
|
|
|
980
|
-
|
|
997
|
+
$ swaggerhub plugins:install https://github.com/someuser/someplugin
|
|
981
998
|
|
|
982
|
-
|
|
999
|
+
Install a plugin from a github slug.
|
|
1000
|
+
|
|
1001
|
+
$ swaggerhub plugins:install someuser/someplugin
|
|
983
1002
|
```
|
|
984
1003
|
|
|
985
|
-
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/
|
|
1004
|
+
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.4.25/src/commands/plugins/install.ts)_
|
|
986
1005
|
|
|
987
1006
|
## `swaggerhub plugins:link`
|
|
988
1007
|
|
|
@@ -990,18 +1009,19 @@ Links a plugin into the CLI for development.
|
|
|
990
1009
|
|
|
991
1010
|
```
|
|
992
1011
|
USAGE
|
|
993
|
-
$ swaggerhub plugins:link
|
|
1012
|
+
$ swaggerhub plugins:link PATH [-h] [--install] [-v]
|
|
994
1013
|
|
|
995
1014
|
ARGUMENTS
|
|
996
1015
|
PATH [default: .] path to plugin
|
|
997
1016
|
|
|
998
1017
|
FLAGS
|
|
999
|
-
-h, --help
|
|
1018
|
+
-h, --help Show CLI help.
|
|
1000
1019
|
-v, --verbose
|
|
1001
|
-
|
|
1020
|
+
--[no-]install Install dependencies after linking the plugin.
|
|
1002
1021
|
|
|
1003
1022
|
DESCRIPTION
|
|
1004
1023
|
Links a plugin into the CLI for development.
|
|
1024
|
+
|
|
1005
1025
|
Installation of a linked plugin will override a user-installed or core plugin.
|
|
1006
1026
|
|
|
1007
1027
|
e.g. If you have a user-installed or core plugin that has a 'hello' command, installing a linked plugin with a 'hello'
|
|
@@ -1012,18 +1032,18 @@ EXAMPLES
|
|
|
1012
1032
|
$ swaggerhub plugins:link myplugin
|
|
1013
1033
|
```
|
|
1014
1034
|
|
|
1015
|
-
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/
|
|
1035
|
+
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.4.25/src/commands/plugins/link.ts)_
|
|
1016
1036
|
|
|
1017
|
-
## `swaggerhub plugins:
|
|
1037
|
+
## `swaggerhub plugins:remove`
|
|
1018
1038
|
|
|
1019
1039
|
Removes a plugin from the CLI.
|
|
1020
1040
|
|
|
1021
1041
|
```
|
|
1022
1042
|
USAGE
|
|
1023
|
-
$ swaggerhub plugins:
|
|
1043
|
+
$ swaggerhub plugins:remove [PLUGIN...] [-h] [-v]
|
|
1024
1044
|
|
|
1025
1045
|
ARGUMENTS
|
|
1026
|
-
PLUGIN plugin to uninstall
|
|
1046
|
+
PLUGIN... plugin to uninstall
|
|
1027
1047
|
|
|
1028
1048
|
FLAGS
|
|
1029
1049
|
-h, --help Show CLI help.
|
|
@@ -1035,18 +1055,36 @@ DESCRIPTION
|
|
|
1035
1055
|
ALIASES
|
|
1036
1056
|
$ swaggerhub plugins:unlink
|
|
1037
1057
|
$ swaggerhub plugins:remove
|
|
1058
|
+
|
|
1059
|
+
EXAMPLES
|
|
1060
|
+
$ swaggerhub plugins:remove myplugin
|
|
1038
1061
|
```
|
|
1039
1062
|
|
|
1063
|
+
## `swaggerhub plugins:reset`
|
|
1064
|
+
|
|
1065
|
+
Remove all user-installed and linked plugins.
|
|
1066
|
+
|
|
1067
|
+
```
|
|
1068
|
+
USAGE
|
|
1069
|
+
$ swaggerhub plugins:reset [--hard] [--reinstall]
|
|
1070
|
+
|
|
1071
|
+
FLAGS
|
|
1072
|
+
--hard Delete node_modules and package manager related files in addition to uninstalling plugins.
|
|
1073
|
+
--reinstall Reinstall all plugins after uninstalling.
|
|
1074
|
+
```
|
|
1075
|
+
|
|
1076
|
+
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.4.25/src/commands/plugins/reset.ts)_
|
|
1077
|
+
|
|
1040
1078
|
## `swaggerhub plugins:uninstall`
|
|
1041
1079
|
|
|
1042
1080
|
Removes a plugin from the CLI.
|
|
1043
1081
|
|
|
1044
1082
|
```
|
|
1045
1083
|
USAGE
|
|
1046
|
-
$ swaggerhub plugins:uninstall PLUGIN...
|
|
1084
|
+
$ swaggerhub plugins:uninstall [PLUGIN...] [-h] [-v]
|
|
1047
1085
|
|
|
1048
1086
|
ARGUMENTS
|
|
1049
|
-
PLUGIN plugin to uninstall
|
|
1087
|
+
PLUGIN... plugin to uninstall
|
|
1050
1088
|
|
|
1051
1089
|
FLAGS
|
|
1052
1090
|
-h, --help Show CLI help.
|
|
@@ -1058,20 +1096,23 @@ DESCRIPTION
|
|
|
1058
1096
|
ALIASES
|
|
1059
1097
|
$ swaggerhub plugins:unlink
|
|
1060
1098
|
$ swaggerhub plugins:remove
|
|
1099
|
+
|
|
1100
|
+
EXAMPLES
|
|
1101
|
+
$ swaggerhub plugins:uninstall myplugin
|
|
1061
1102
|
```
|
|
1062
1103
|
|
|
1063
|
-
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/
|
|
1104
|
+
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.4.25/src/commands/plugins/uninstall.ts)_
|
|
1064
1105
|
|
|
1065
|
-
## `swaggerhub plugins:
|
|
1106
|
+
## `swaggerhub plugins:unlink`
|
|
1066
1107
|
|
|
1067
1108
|
Removes a plugin from the CLI.
|
|
1068
1109
|
|
|
1069
1110
|
```
|
|
1070
1111
|
USAGE
|
|
1071
|
-
$ swaggerhub plugins:
|
|
1112
|
+
$ swaggerhub plugins:unlink [PLUGIN...] [-h] [-v]
|
|
1072
1113
|
|
|
1073
1114
|
ARGUMENTS
|
|
1074
|
-
PLUGIN plugin to uninstall
|
|
1115
|
+
PLUGIN... plugin to uninstall
|
|
1075
1116
|
|
|
1076
1117
|
FLAGS
|
|
1077
1118
|
-h, --help Show CLI help.
|
|
@@ -1083,6 +1124,9 @@ DESCRIPTION
|
|
|
1083
1124
|
ALIASES
|
|
1084
1125
|
$ swaggerhub plugins:unlink
|
|
1085
1126
|
$ swaggerhub plugins:remove
|
|
1127
|
+
|
|
1128
|
+
EXAMPLES
|
|
1129
|
+
$ swaggerhub plugins:unlink myplugin
|
|
1086
1130
|
```
|
|
1087
1131
|
|
|
1088
1132
|
## `swaggerhub plugins:update`
|
|
@@ -1101,7 +1145,7 @@ DESCRIPTION
|
|
|
1101
1145
|
Update installed plugins.
|
|
1102
1146
|
```
|
|
1103
1147
|
|
|
1104
|
-
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/
|
|
1148
|
+
_See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.4.25/src/commands/plugins/update.ts)_
|
|
1105
1149
|
|
|
1106
1150
|
## `swaggerhub project:api:add`
|
|
1107
1151
|
|
|
@@ -1125,7 +1169,7 @@ EXAMPLES
|
|
|
1125
1169
|
$ swaggerhub project:api:add organization/project_name my_api
|
|
1126
1170
|
```
|
|
1127
1171
|
|
|
1128
|
-
_See code: [src/commands/project/api/add.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
1172
|
+
_See code: [src/commands/project/api/add.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/project/api/add.js)_
|
|
1129
1173
|
|
|
1130
1174
|
## `swaggerhub project:api:remove`
|
|
1131
1175
|
|
|
@@ -1149,7 +1193,7 @@ EXAMPLES
|
|
|
1149
1193
|
$ swaggerhub project:api:remove organization/project_name my_api
|
|
1150
1194
|
```
|
|
1151
1195
|
|
|
1152
|
-
_See code: [src/commands/project/api/remove.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
1196
|
+
_See code: [src/commands/project/api/remove.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/project/api/remove.js)_
|
|
1153
1197
|
|
|
1154
1198
|
## `swaggerhub project:create`
|
|
1155
1199
|
|
|
@@ -1163,10 +1207,10 @@ ARGUMENTS
|
|
|
1163
1207
|
OWNER/PROJECT_NAME The new project to create on Swaggerhub
|
|
1164
1208
|
|
|
1165
1209
|
FLAGS
|
|
1166
|
-
-a, --apis=<value>
|
|
1167
|
-
-d, --domains=<value>
|
|
1168
|
-
-h, --help
|
|
1169
|
-
|
|
1210
|
+
-a, --apis=<value> Comma separated list of api names to include in project
|
|
1211
|
+
-d, --domains=<value> Comma separated list of domain names to include in project
|
|
1212
|
+
-h, --help Show CLI help.
|
|
1213
|
+
--description=<value> Description of project
|
|
1170
1214
|
|
|
1171
1215
|
DESCRIPTION
|
|
1172
1216
|
Creates a new project in SwaggerHub.
|
|
@@ -1185,7 +1229,7 @@ EXAMPLES
|
|
|
1185
1229
|
$ swaggerhub project:create organization/new_project_name -a "testapi1" -d "testdomain3" --description "description"
|
|
1186
1230
|
```
|
|
1187
1231
|
|
|
1188
|
-
_See code: [src/commands/project/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
1232
|
+
_See code: [src/commands/project/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/project/create.js)_
|
|
1189
1233
|
|
|
1190
1234
|
## `swaggerhub project:delete`
|
|
1191
1235
|
|
|
@@ -1208,7 +1252,7 @@ EXAMPLES
|
|
|
1208
1252
|
$ swaggerhub project:delete organization/project_name
|
|
1209
1253
|
```
|
|
1210
1254
|
|
|
1211
|
-
_See code: [src/commands/project/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
1255
|
+
_See code: [src/commands/project/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/project/delete.js)_
|
|
1212
1256
|
|
|
1213
1257
|
## `swaggerhub project:domain:add`
|
|
1214
1258
|
|
|
@@ -1232,7 +1276,7 @@ EXAMPLES
|
|
|
1232
1276
|
$ swaggerhub project:domain:add organization/project_name my_domain
|
|
1233
1277
|
```
|
|
1234
1278
|
|
|
1235
|
-
_See code: [src/commands/project/domain/add.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
1279
|
+
_See code: [src/commands/project/domain/add.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/project/domain/add.js)_
|
|
1236
1280
|
|
|
1237
1281
|
## `swaggerhub project:domain:remove`
|
|
1238
1282
|
|
|
@@ -1256,7 +1300,7 @@ EXAMPLES
|
|
|
1256
1300
|
$ swaggerhub project:domain:remove organization/project_name my_domain
|
|
1257
1301
|
```
|
|
1258
1302
|
|
|
1259
|
-
_See code: [src/commands/project/domain/remove.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
1303
|
+
_See code: [src/commands/project/domain/remove.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/project/domain/remove.js)_
|
|
1260
1304
|
|
|
1261
1305
|
## `swaggerhub project:get`
|
|
1262
1306
|
|
|
@@ -1279,7 +1323,7 @@ EXAMPLES
|
|
|
1279
1323
|
$ swaggerhub project:get organization/project_name
|
|
1280
1324
|
```
|
|
1281
1325
|
|
|
1282
|
-
_See code: [src/commands/project/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
1326
|
+
_See code: [src/commands/project/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/project/get.js)_
|
|
1283
1327
|
|
|
1284
1328
|
## `swaggerhub project:list`
|
|
1285
1329
|
|
|
@@ -1304,7 +1348,7 @@ EXAMPLES
|
|
|
1304
1348
|
$ swaggerhub project:list organization
|
|
1305
1349
|
```
|
|
1306
1350
|
|
|
1307
|
-
_See code: [src/commands/project/list.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
1351
|
+
_See code: [src/commands/project/list.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/project/list.js)_
|
|
1308
1352
|
|
|
1309
1353
|
## `swaggerhub project:member:list`
|
|
1310
1354
|
|
|
@@ -1327,7 +1371,7 @@ EXAMPLES
|
|
|
1327
1371
|
$ swaggerhub project:member:list organisation/project_name
|
|
1328
1372
|
```
|
|
1329
1373
|
|
|
1330
|
-
_See code: [src/commands/project/member/list.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.
|
|
1374
|
+
_See code: [src/commands/project/member/list.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.9.1/src/commands/project/member/list.js)_
|
|
1331
1375
|
<!-- commandsstop -->
|
|
1332
1376
|
|
|
1333
1377
|
# Plugins
|
package/oclif.manifest.json
CHANGED
package/package.json
CHANGED
|
@@ -1,42 +1,43 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "swaggerhub-cli",
|
|
3
3
|
"description": "SwaggerHub CLI",
|
|
4
|
-
"version": "0.9.
|
|
4
|
+
"version": "0.9.1",
|
|
5
5
|
"author": "SmartBear",
|
|
6
6
|
"bin": {
|
|
7
7
|
"swaggerhub": "./bin/run"
|
|
8
8
|
},
|
|
9
9
|
"bugs": "https://github.com/SmartBear/swaggerhub-cli/issues",
|
|
10
10
|
"dependencies": {
|
|
11
|
-
"@oclif/core": "^3.3
|
|
12
|
-
"@oclif/plugin-help": "^6.0.
|
|
13
|
-
"@oclif/plugin-plugins": "^
|
|
11
|
+
"@oclif/core": "^3.26.3",
|
|
12
|
+
"@oclif/plugin-help": "^6.0.21",
|
|
13
|
+
"@oclif/plugin-plugins": "^5.0.21",
|
|
14
14
|
"deep-extend": "^0.6.0",
|
|
15
15
|
"fs-extra": "^11.1.1",
|
|
16
16
|
"inquirer": "^8.2.5",
|
|
17
17
|
"js-yaml": "^4.1.0",
|
|
18
18
|
"json-templates": "^5.0.0",
|
|
19
19
|
"node-fetch": "^2.6.12",
|
|
20
|
-
"semver": "^7.
|
|
20
|
+
"semver": "^7.6.0"
|
|
21
21
|
},
|
|
22
22
|
"devDependencies": {
|
|
23
|
-
"@oclif/test": "^2.
|
|
24
|
-
"chai": "^4.3.
|
|
25
|
-
"
|
|
26
|
-
"eslint
|
|
23
|
+
"@oclif/test": "^3.2.10",
|
|
24
|
+
"chai": "^4.3.10",
|
|
25
|
+
"sinon": "^18.0.0",
|
|
26
|
+
"eslint": "^9.0.0",
|
|
27
|
+
"eslint-plugin-chai-friendly": "^1.0.0",
|
|
27
28
|
"eslint-plugin-immutable": "^1.0.0",
|
|
28
29
|
"eslint-plugin-mocha": "^10.1.0",
|
|
29
30
|
"eslint-plugin-node": "^11.1.0",
|
|
30
31
|
"globby": "^14.0.0",
|
|
31
|
-
"husky": "^
|
|
32
|
+
"husky": "^9.0.1",
|
|
32
33
|
"mocha": "^10.2.0",
|
|
33
34
|
"nock": "^13.3.2",
|
|
34
|
-
"nyc": "^
|
|
35
|
+
"nyc": "^17.0.0",
|
|
35
36
|
"rewire": "^7.0.0",
|
|
36
37
|
"tmp": "^0.2.1"
|
|
37
38
|
},
|
|
38
39
|
"engines": {
|
|
39
|
-
"node": ">=
|
|
40
|
+
"node": ">=18.0.0"
|
|
40
41
|
},
|
|
41
42
|
"files": [
|
|
42
43
|
"/bin",
|
package/src/config/index.js
CHANGED
|
@@ -21,9 +21,10 @@ const setConfig = update => {
|
|
|
21
21
|
|
|
22
22
|
const isURLValid = () => {
|
|
23
23
|
const { SWAGGERHUB_URL } = getConfig()
|
|
24
|
+
const url = new URL(SWAGGERHUB_URL)
|
|
24
25
|
return swaggerhubUrlRegex.test(SWAGGERHUB_URL) ||
|
|
25
|
-
|
|
26
|
-
|
|
26
|
+
(!url.hostname.endsWith('api.swaggerhub.com') && url.pathname.endsWith('/v1')) ||
|
|
27
|
+
url.hostname === 'localhost'
|
|
27
28
|
}
|
|
28
29
|
|
|
29
30
|
module.exports = {
|