| 1 | name: autofix.ci # needed to securely identify the workflow |
| 2 | |
| 3 | on: |
| 4 | pull_request: |
| 5 | branches-ignore: |
| 6 | - 'renovate/**' |
| 7 | permissions: |
| 8 | contents: read |
| 9 | |
| 10 | concurrency: ${{ github.workflow }}-${{ github.ref }} |
| 11 | |
| 12 | jobs: |
| 13 | autofix: |
| 14 | runs-on: ubuntu-latest |
| 15 | steps: |
| 16 | - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 |
| 17 | |
| 18 | - uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0 |
| 19 | # uses version from "packageManager" field in package.json |
| 20 | |
| 21 | - name: Setup Node.js |
| 22 | uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0 |
| 23 | with: |
| 24 | cache: pnpm |
| 25 | node-version-file: '.node-version' |
| 26 | |
| 27 | - name: Install Packages |
| 28 | run: | |
| 29 | pnpm install --frozen-lockfile |
| 30 | env: |
| 31 | CYPRESS_CACHE_FOLDER: .cache/Cypress |
| 32 | |
| 33 | - name: Fix Linting |
| 34 | shell: bash |
| 35 | run: pnpm -w run lint:fix |
| 36 | |
| 37 | - name: Sync `./src/config.type.ts` with `./src/schemas/config.schema.yaml` |
| 38 | shell: bash |
| 39 | run: pnpm run --filter mermaid types:build-config |
| 40 | |
| 41 | - name: Build Docs |
| 42 | working-directory: ./packages/mermaid |
| 43 | run: pnpm run docs:build |
| 44 | |
| 45 | - uses: autofix-ci/action@635ffb0c9798bd160680f18fd73371e355b85f27 # main |
| 46 | |