Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apply Clang format #842

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open

Apply Clang format #842

wants to merge 1 commit into from

Conversation

tbeu
Copy link

@tbeu tbeu commented Feb 18, 2025

483950d introduced .clang-format which however is not respected in current v4.0.8 (55db144). Hence, contributions via PR might get somehow noisy as this one shows.

@tbeu
Copy link
Author

tbeu commented Feb 18, 2025

I recommend to setup an optional pre-commit hook that checks for clang-format.

Here's what I used as .pre-commit-config.yaml

repos:
- repo: https://github.com/pre-commit/mirrors-clang-format
  rev: v19.1.2
  hooks:
  - id: clang-format
    files: ^(test\/.+\.cc|test\/fuzz\/.+\.c|.+\.[ch])$

There is some CI tooling around pre-commit hooks, which I'd recommend additionally. See https://github.com/pre-commit-ci for instance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant