-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #14 from Bandwidth/DX-3033
Dx 3033 Migrate to Public NPM
- Loading branch information
Showing
8 changed files
with
1,163 additions
and
4,012 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,34 @@ | ||
# oas-linter-cli | ||
|
||
This is a CLI tool that enables users to run an OAS (Open API Spec) file through the DevX ruleset before opening a pull request against [api-specs](https://github.com/Bandwidth/api-specs) | ||
This is a CLI tool that enables users to run an OAS (Open API Spec) file through Bandwidth's custom [Stoplight ruleset](https://docs.stoplight.io/docs/spectral/e5b9616d6d50c-rulesets). | ||
|
||
## Setup and Install | ||
|
||
```sh | ||
# if your npm profile isnt setup to download npm packages published to githubs npm registry - run these commands first | ||
npm login --registry https://npm.pkg.github.com # Requires a github token with Bandwidth SSO access | ||
npm config set @Bandwidth:registry https://npm.pkg.github.com | ||
|
||
# note the uppercase `B` | ||
npm install -g @Bandwidth/oas-linter-cli | ||
npm install -g @bandwidth/oas-linter-cli | ||
``` | ||
|
||
## Usage | ||
|
||
```sh | ||
bw-oas-lint -h # Help | ||
bw-oas-lint lint ../path/to/my/spec.yml # must be in Yaml format | ||
|
||
# add -s flag to save the terminal output to a .json file in your home directory | ||
bw-oas-linter lint ../path/to/my/spec.yml # json also supported | ||
``` | ||
|
||
## Uninstall | ||
### Options | ||
|
||
Run `bw-oas-linter lint -h` for a list of options. | ||
|
||
| Flag | Description | | ||
|:----:|:------------| | ||
| -s | Save linter result to users home directory | | ||
| -j | Output JSON | | ||
| -r | Path to custom spectral ruleset file | | ||
| -h | Print help menu | | ||
| -v | Print package version | | ||
|
||
|
||
## Uninstall | ||
|
||
```sh | ||
# note the lowercase `b` | ||
npm uninstall -g @bandwidth/oas-linter-cli | ||
``` |
Oops, something went wrong.