Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Lint

# ci.yml in this repo is a reusable workflow for the library repos and never
# runs here, so this repo's own Markdown needs a workflow of its own.

on:
push:
pull_request:

jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Setup Python
uses: actions/setup-python@v6
with:
python-version: '3.13'
- name: Install pre-commit
run: pip install pre-commit
- name: Run linters
run: pre-commit run --all-files
18 changes: 18 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: "3e8a8703264a2f4a69428a0aa4dcb512790b2c8c" # frozen: v6.0.0
hooks:
- id: check-json
- id: check-yaml
- id: check-merge-conflict
- id: end-of-file-fixer
- id: trailing-whitespace
- repo: https://github.com/igorshubovych/markdownlint-cli
rev: "5b5dddc4fb0f83c3ea1fc5616fa63e115dce83e0" # frozen: v0.49.1
hooks:
- id: markdownlint
args:
- --fix
# GitHub injects this into the PR description, so it's a fragment
# rather than a document and deliberately has no top-level heading.
exclude: ^PULL_REQUEST_TEMPLATE/