generated from camaraproject/Template_API_Repository
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
650115f
commit b038bf2
Showing
1 changed file
with
36 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
--- | ||
# CAMARA Project - workflow configuration to manually run CAMARA OAS rules | ||
# see https://docs.github.com/en/actions/using-workflows/manually-running-a-workflow | ||
# 31.01.2024 - initial version | ||
|
||
name: Spectral manual run | ||
|
||
on: workflow_dispatch | ||
|
||
concurrency: | ||
group: ${{ github.ref }}-${{ github.workflow }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
build: | ||
name: Spectral linting | ||
runs-on: ubuntu-latest | ||
permissions: | ||
# Give the default GITHUB_TOKEN write permission to commit and push, comment issues & post new PR | ||
# Remove the ones you do not need | ||
contents: write | ||
issues: write | ||
pull-requests: write | ||
steps: | ||
# Git Checkout | ||
- name: Checkout Code | ||
uses: actions/checkout@v4 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
fetch-depth: 0 # If you use VALIDATE_ALL_CODEBASE = true, you can remove this line to improve performances | ||
- name: Install Spectral | ||
run: npm install -g @stoplight/spectral | ||
- name: Install Spectral functions | ||
run: npm install -g @stoplight/spectral-functions | ||
- name: Run Spectral linting | ||
run: spectral lint code/API_definitions/*.yaml --verbose --ruleset .spectral.yml |