From b33d1f2ff6548bf3ca0bf6de047afece849396ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?K=C3=BCr=C5=9Fat=20Yurt?= <57598663+kursatyurt@users.noreply.github.com> Date: Sun, 19 Mar 2023 03:26:49 +0100 Subject: [PATCH] Add pre-commit information to website --- _docs_v7/Style-Guide.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/_docs_v7/Style-Guide.md b/_docs_v7/Style-Guide.md index 90c36b2b..fe2666f5 100644 --- a/_docs_v7/Style-Guide.md +++ b/_docs_v7/Style-Guide.md @@ -25,6 +25,8 @@ Patch releases cannot break backward compatibility. SU2 is written for C++11, the formatting rules are defined in a `clang-format` file located in the root of the repository. **New files must follow the formatting rules exactly.** +SU2 uses pre-commit to enforce a consistent formatting. To use, [install pre-commit](https://pre-commit.com/#install) and run `pre-commit install` at the root of the project. You can now force the formatting on all files with `pre-commit run -a`. This will also run all pre-commit hooks before each commit, preventing dirty commits in the repository. + ### Files, functions, and variables Basic recommendations for creating files, functions, and variables: