Skip to content

Commit

Permalink
Merge pull request mycloudnexus#3 from BeStateless/vacuum-linting
Browse files Browse the repository at this point in the history
Add Vacuum linting GH Action
  • Loading branch information
michaelbrown-stateless authored Oct 1, 2024
2 parents 01d485a + ce66051 commit 873ec53
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/lint-spec.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: Vacuum open API linting
run-name: Linting OpenAPI spec with Vacuum
on: [push]
jobs:
vacuum-lint:
runs-on: ubuntu-24.04
container: dshanley/vacuum:v0.13.1
steps:
- uses: actions/checkout@v4
- name: Generate Vacuum HTML Reports
run: mkdir -p reports; for FILEPATH in specs/ccapi*.json; do FILE="$(echo $FILEPATH | cut -d '/' -f2 | cut -d '.' -f1)"; vacuum html-report "${FILEPATH}" "reports/report-${FILE}.html"; done
shell: bash
- name: Archive Vacuum HTML Reports
uses: actions/upload-artifact@v3
with:
name: Vacuum HTML Reports
path: reports/*.html
- name: Lint with Vaccum
run: vacuum lint specs/ccapi* || true
shell: bash

1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
lts/*

0 comments on commit 873ec53

Please sign in to comment.