Skip to content

Commit

Permalink
add spectral to ci
Browse files Browse the repository at this point in the history
  • Loading branch information
IgorPolyakov committed Aug 9, 2024
1 parent 8b0fc7e commit 7ae7df5
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
10 changes: 10 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,16 @@ jobs:
with:
go_version: 1.22

lint-oapi:
name: Run Spectral
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- uses: stoplightio/spectral-action@latest
with:
file_glob: 'api/.yaml'
spectral_ruleset: "configs/spectral/spectral.yaml"
test:
name: Run Tests
runs-on: ubuntu-latest
Expand Down
3 changes: 3 additions & 0 deletions .spectral.yaml → configs/spectral/spectral.yaml
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
extends: ["spectral:oas", "spectral:asyncapi"]

rules:
operation-description: "off"

0 comments on commit 7ae7df5

Please sign in to comment.