mirror of
https://github.com/supabase/supabase.git
synced 2026-10-17 15:19:08 +03:00
45 lines
1.4 KiB
YAML
45 lines
1.4 KiB
YAML
name: '[Docs] Lint v2'
|
|
on:
|
|
pull_request:
|
|
paths:
|
|
- '.github/workflows/docs-lint-v2.yml'
|
|
- 'supa-mdx-lint.config.toml'
|
|
- 'apps/docs/content/**'
|
|
|
|
env:
|
|
CARGO_NET_GIT_FETCH_WITH_CLI: true
|
|
|
|
jobs:
|
|
supa-mdx-lint:
|
|
name: supa-mdx-lint
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
with:
|
|
sparse-checkout: |
|
|
supa-mdx-lint.config.toml
|
|
apps/docs/content
|
|
- name: cache cargo
|
|
id: cache-cargo
|
|
uses: actions/cache@v4
|
|
with:
|
|
path: |
|
|
~/.cargo/bin/
|
|
~/.cargo/registry/index/
|
|
~/.cargo/registry/cache/
|
|
~/.cargo/git/db/
|
|
key: e23c860111349d8bac17b78b1fe632afe84223f9
|
|
- name: install linter
|
|
if: steps.cache-cargo.outputs.cache-hit != 'true'
|
|
run: cargo install --locked --git https://github.com/supabase-community/supa-mdx-lint --rev e23c860111349d8bac17b78b1fe632afe84223f9
|
|
- name: install reviewdog
|
|
uses: reviewdog/action-setup@3f401fe1d58fe77e10d665ab713057375e39b887 # v1.3.0
|
|
with:
|
|
reviewdog_version: v0.20.2
|
|
- name: run linter
|
|
env:
|
|
REVIEWDOG_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
run: |
|
|
set -o pipefail
|
|
supa-mdx-lint apps/docs/content/guides/getting-started apps/docs/content/guides/ai --format rdf | reviewdog -f=rdjsonl -reporter=github-pr-review
|