Bobby Bruce has uploaded this change for review. ( https://gem5-review.googlesource.com/c/public/gem5/+/63791?usp=email )

Change subject: misc: Reword CONTRIBUTING.md pre-commit documentation
......................................................................

misc: Reword CONTRIBUTING.md pre-commit documentation

This is a slight-rewording to make the usage of the pre-commit checks
clearer.

Change-Id: I73f9bfe7143a527c9e495cdf4d51e2aa857b43d5
---
M CONTRIBUTING.md
1 file changed, 19 insertions(+), 5 deletions(-)



diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index d81cd9c..ae771d3 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -143,14 +143,17 @@
 To help ensure the gem5 style guide is maintained, we use [pre-commit](
 https://pre-commit.com) to run checks on changes to be contributed.

-To setup pre-commit, run the following in your gem5 directory.
+To setup pre-commit, run the following in your gem5 directory to install the
+pre-commit and commit message hooks.

 ```sh
 pip install pre-commit
 pre-commit install -t pre-commit -t commit-msg
 ```

-When you run a `git commit` command the pre-commit will run checks on your
+The hooks are also automatically installed when gem5 is compiled.
+
+When you run a `git commit` command the pre-commit hook will run checks on your
 committed code. The commit will be blocked if a check fails.

The same checks are run as part of Gerrit's CI tests (those required to obtain
@@ -158,11 +161,10 @@
Therefore setting up pre-commit in your local gem5 development environment is
 recommended.

-You can automatically format your changed code to pass the pre-commit tests by
-running:
+You can automatically format files to pass the pre-commit tests by running:

 ```sh
-pre-commit run
+pre-commit run --files <files to format>
 ```

 Requirements for change descriptions

--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/63791?usp=email To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: I73f9bfe7143a527c9e495cdf4d51e2aa857b43d5
Gerrit-Change-Number: 63791
Gerrit-PatchSet: 1
Gerrit-Owner: Bobby Bruce <bbr...@ucdavis.edu>
Gerrit-MessageType: newchange
_______________________________________________
gem5-dev mailing list -- gem5-dev@gem5.org
To unsubscribe send an email to gem5-dev-le...@gem5.org

Reply via email to