#687 WIP to help with the Issue discussion #8
Workflow file for this run
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
name: Validation of CALM Samples | |
on: | |
pull_request: | |
branches: | |
- "main" | |
paths: | |
- "calm/draft/**" | |
- "calm/pattern/**" | |
- "calm/samples/**" | |
- "shared/src/spectral/**" | |
push: | |
branches: | |
- "main" | |
paths: | |
- "calm/draft/**" | |
- "calm/pattern/**" | |
- "calm/samples/**" | |
- "shared/src/spectral/**" | |
jobs: | |
spectrals: | |
name: Run Spectral | |
runs-on: ubuntu-latest | |
steps: | |
# Check out the repository | |
- uses: actions/checkout@v4 | |
# Run Spectral | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: v20 | |
- name: Install workspace | |
run: npm ci | |
- name: Build workspace | |
run: npm run build | |
- name: Install Spectral-CLI | |
run: npm install @stoplight/spectral-cli | |
- name: Run Example Spectral Linting | |
run: npx spectral lint --ruleset ./shared/dist/spectral/rules-instantiation.js 'calm/samples/api-gateway-instantiation(*.json|*.yaml)' | |