Skip to content

Commit 99fefc8

Browse files
Add pre-commit to requirements and README (#2491)
* Initial plan * Add pre-commit to requirements and README Co-authored-by: ericholscher <[email protected]> --------- Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: ericholscher <[email protected]>
1 parent 8f734be commit 99fefc8

File tree

2 files changed

+16
-0
lines changed

2 files changed

+16
-0
lines changed

README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,20 @@ WIP (Work In Progress) Docs on how to do this:
5757

5858
2. In the repository root directory (`www` by default), run `pip install -r requirements.txt` to install sphinx and other requirements.
5959

60+
### Setting up pre-commit hooks
61+
62+
This repository uses [pre-commit](https://pre-commit.com/) to run automated checks on files before committing. After installing the requirements, set up the pre-commit hooks:
63+
64+
```
65+
pre-commit install
66+
```
67+
68+
The hooks will now run automatically when you commit changes. You can also run them manually:
69+
70+
```
71+
pre-commit run --all-files
72+
```
73+
6074
### Previewing the docs locally
6175

6276
> Remember to activate the virtual environment using the appropriate command for your OS and Shell before running the following commands.

requirements.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,3 +35,5 @@ sphinx-notfound-page==1.1.0
3535
sphinxext-opengraph==0.9.1
3636
# For social cards
3737
matplotlib==3.9.4
38+
# For pre-commit hooks
39+
pre-commit==4.0.1

0 commit comments

Comments
 (0)