Skip to content

Commit

Permalink
meta; update README, icon, screenshot refs #1
Browse files Browse the repository at this point in the history
  • Loading branch information
MikeRalphson committed Jul 3, 2018
1 parent 459f299 commit 6a83016
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 16 deletions.
20 changes: 16 additions & 4 deletions README.md
@@ -1,11 +1,18 @@
# openapi-lint README

This extension can be used to validate and lint OpenAPI 3.0.x documents
This extension can be used to validate and [lint](https://en.wikipedia.org/wiki/Lint_(software)) OpenAPI 3.0.x documents. It provides two Visual Studio Code commands:

* OpenAPI Validate - which fully validates your OpenAPI document against the [specification](https://github.com/OAI/OpenAPI-Specification/blob/master/versions/3.0.1.md)
* OpenAPI Lint - which additionally applies a lightly-opinionated set of best-practices

The validator enforces restrictions which cannot be expressed by the JSON Schema which drives the intellisense features, so it will pick up on more errors.

The best documentation currently for the linter rules is that of [Speccy](http://speccy.io/rules/), which shares code with this project. The linter [rules format](https://mermade.github.io/oas-kit/linter-rules.html) is also documented.

## Features

* Validation using `oas-validator`
* Linting using `oas-linter`
* Validation using [oas-validator](https://github.com/Mermade/oas-kit/tree/master/packages/oas-validator) from [OAS-Kit](https://mermade.github.io/oas-kit/)
* Linting using [oas-linter](https://github.com/Mermade/oas-kit/tree/master/packages/oas-validator) also from OAS-Kit
* v3 intellisense for files named `openapi.json`, `openapi.yaml`, `openapi.yml`
* v2 intellisense for files named `swagger.json`, `swagger.yaml`, `swagger.yml`
* Conversion between JSON and YAML
Expand All @@ -19,7 +26,7 @@ This extension can be used to validate and lint OpenAPI 3.0.x documents

## Screenshots

* Coming soon!
![screenshot](./images/vscode-lint.png)

## Requirements

Expand All @@ -33,6 +40,11 @@ No configuration is currently possible or needed.

* Messages need better formatting
* Jump-to-error functionality not implemented yet
* No way to override/amend linter rules yet

## Credits

* Icon based upon [Icons8](http://icons8.com/)

## Release Notes

Expand Down
Binary file added images/icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/vscode-lint.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
26 changes: 14 additions & 12 deletions package.json
Expand Up @@ -2,13 +2,14 @@
"name": "openapi-lint",
"displayName": "openapi-lint",
"description": "OpenAPI (Swagger) 3.0.x validator and linter",
"version": "0.2.0",
"version": "0.2.1",
"publisher": "mermade",
"engines": {
"vscode": "^1.24.0"
},
"categories": [
"Linters"
"Linters",
"Snippets"
],
"activationEvents": [
"onCommand:extension.openapi-validate",
Expand All @@ -19,21 +20,21 @@
"main": "./extension",
"contributes": {
"commands": [
{
"command": "extension.openapi-to-json",
"title": "OpenAPI to JSON"
},
{
"command": "extension.openapi-to-yaml",
"title": "OpenAPI to YAML"
},
{
"command": "extension.openapi-validate",
"title": "OpenAPI Validate"
},
{
"command": "extension.openapi-lint",
"title": "OpenAPI Lint"
},
{
"command": "extension.openapi-to-json",
"title": "OpenAPI to JSON"
},
{
"command": "extension.openapi-to-yaml",
"title": "OpenAPI to YAML"
}
],
"snippets": [
Expand All @@ -48,11 +49,11 @@
],
"yamlValidation": [
{
"fileMatch": "*openapi*.yaml",
"fileMatch": "openapi.yaml",
"url": "./schemas/gnostic-3.0.json"
},
{
"fileMatch": "*openapi*.yml",
"fileMatch": "openapi.yml",
"url": "./schemas/gnostic-3.0.json"
},
{
Expand All @@ -75,6 +76,7 @@
}
]
},
"icon": "images/icon.png",
"scripts": {
"postinstall": "node ./node_modules/vscode/bin/install",
"test": "node ./node_modules/vscode/bin/test"
Expand Down

0 comments on commit 6a83016

Please sign in to comment.