From ad1e3339721358f3eaf16d3d5fbfa287c3685d4c Mon Sep 17 00:00:00 2001 From: Kang Minchul Date: Wed, 6 Jul 2022 22:13:34 +0900 Subject: [PATCH] doc: Add pre-commit installation command in CONTRIBUTING.md pre-commit is installed via pip. If this CONTRIBUTING.md doesn't guide how to install the package, future contributors cannot know how to download and run the command below. $ pre-commit install So this commit adds pre-commit package installation command in CONTRIBUTING.md Signed-off-by: Kang Minchul --- CONTRIBUTING.md | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 37d7a5cf7..b6f69b9c8 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -19,7 +19,13 @@ with the help of [pre-commit](https://pre-commit.com) and [clang-format](https://clang.llvm.org/docs/ClangFormat.html) so that our source code has a consistent coding style at all times. -You can install pre-commit as follows. +You need to install pre-commit package but please note that python version 3.7 +or higher is required. The installation can be done as follows. + + $ python3 -m pip install pre-commit + +Then you can simply install a pre-commit hook inside the uftrace source +directory as follows. $ pre-commit install pre-commit installed at .git/hooks/pre-commit