Skip to content

Conversation

@rwgk
Copy link
Collaborator

@rwgk rwgk commented Jul 8, 2021

EXPERIMENTAL integration of clang-format hook into pre-commit.
NOT TO BE MERGED until after the 2.7 release.

At the moment this DRAFT PR is is to see what's involved and what the result looks like.

Using the same docker container as used for clang-tidy (silkeh/clang:12).

@rwgk rwgk mentioned this pull request Jul 8, 2021
rwgk added 6 commits July 9, 2021 07:15
* Inserting clang-format using the same docker container as used for clang-tidy (silkeh/clang:12).

* Removing stray semicolons (discovered by running clang-format v12 followed by tools/check-style.sh).

* Manually moving `// NOLINT` and `// NOLINTNEXTLINE` comments so that clang-format does not move them to the wrong places.

* Manually reformatting comments related to `static_assert`s so that clang-format does not need two passes.

* git diff -U0 --no-color HEAD^ | python3 $HOME/clone/llvm-project/clang/tools/clang-format/clang-format-diff.py -p1 -style=file -i
…r the just-merged PR pybind#3080. Also rerunning clang-format-diff.py to pick up a few fixes missed before.
@rwgk rwgk force-pushed the global_clang_format_pure_llvm branch from e16802a to cd98fb0 Compare July 9, 2021 17:01
@rwgk rwgk closed this Jul 13, 2021
@rwgk rwgk deleted the global_clang_format_pure_llvm branch July 13, 2021 22:54
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