libei/.pre-commit-config.yaml
Peter Hutterer a6028a7b87 Format the code with clang-format
clang-format taken from libinput, except for
  ColumnLimit: 100
and some macro definitions (which don't all have an effect anyway...)

It's not perfect but good enough and at least consistent.

Part-of: <https://gitlab.freedesktop.org/libinput/libei/-/merge_requests/383>
2026-03-12 13:55:19 +10:00

28 lines
774 B
YAML

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: end-of-file-fixer
- id: trailing-whitespace
- id: check-merge-conflict
- id: check-symlinks
- id: no-commit-to-branch
args: ['--branch', 'main']
- repo: https://github.com/charliermarsh/ruff-pre-commit
rev: v0.9.4
hooks:
- id: ruff
args: ['--ignore=E741,E501', '.', 'proto/ei-scanner']
- id: ruff-format
args: ['.', 'proto/ei-scanner']
- repo: local
hooks:
- id: ci-fairy-generate-template
name: ci-fairy-generate-template
entry: bash -c 'command -v ci-fairy && ci-fairy generate-template || true'
language: system
- repo: https://github.com/pre-commit/mirrors-clang-format
rev: v20.1.6
hooks:
- id: clang-format
types_or: [c]