tools: Move check-swagger to check-openapi and make it executable.

This commit is contained in:
Hemanth V. Alluri 2019-08-04 21:29:21 +05:30 committed by Tim Abbott
parent 0682f4f12a
commit c90056bdb2
3 changed files with 2 additions and 2 deletions

View File

@ -193,7 +193,7 @@ above.
declared using `REQ`.
You can check your formatting using two helpful tools.
* `tools/check-swagger` will verify the syntax of `zerver/openapi/zulip.yaml`.
* `tools/check-openapi` will verify the syntax of `zerver/openapi/zulip.yaml`.
* `test-backend zerver/tests/test_openapi.py`; this test compares
your documentation against the code and can find many common
mistakes in how arguments are declared.

0
tools/check-swagger → tools/check-openapi Normal file → Executable file
View File

View File

@ -74,7 +74,7 @@ def run():
description="Custom linter checks whitespace formatting"
"of HTML templates.",
fix_arg='--fix')
linter_config.external_linter('swagger', ['node', 'tools/check-swagger'], ['yaml'],
linter_config.external_linter('openapi', ['node', 'tools/check-openapi'], ['yaml'],
description="Validates our OpenAPI/Swagger API documentation"
"(zerver/openapi/zulip.yaml) ")
linter_config.external_linter('shellcheck', ['shellcheck', '-x'], ['sh'],