Skip to content

Commit 7a89c30

Browse files
committed
Add a note in README to run pre-commit hooks locally
1 parent 7ea99bd commit 7a89c30

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

README.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,3 +39,29 @@ $ GIT_USER=<Your GitHub username> yarn deploy
3939
```
4040

4141
If you are using GitHub pages for hosting, this command is a convenient way to build the website and push to the `gh-pages` branch.
42+
43+
### Pre-commit Hook Setup
44+
45+
To ensure code quality and consistency, we use `pre-commit` hooks. Here's how to set up and run the pre-commit hook locally:
46+
47+
1. **Install pre-commit:**
48+
49+
If `pre-commit` isn't already installed, you can install it using `pip`:
50+
51+
```bash
52+
$ pip install pre-commit
53+
```
54+
2. **Install the pre-commit hooks:**
55+
56+
Once `pre-commit` is installed, set up the hooks for the repository by running:
57+
58+
```bash
59+
$ pre-commit install
60+
```
61+
3. **Run pre-commit hooks manually:**
62+
63+
To run the `pre-commit` hooks on all files manually, use:
64+
65+
```bash
66+
$ pre-commit run --all-files
67+
```

0 commit comments

Comments
 (0)