Skip to content

Commit 20ad1a1

Browse files
authored
Add pre-commit hook setup instructions to contributing guide (#2882)
* Add pre-commit hook setup instructions to contributing guide * Use uv tool install prek instead of .tox path * Add config-types instruction to CLI option guide
1 parent 294acb6 commit 20ad1a1

1 file changed

Lines changed: 13 additions & 6 deletions

File tree

docs/development-contributing.md

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,22 +29,26 @@ $ tox run -e dev
2929

3030
.tox/dev is a Python environment you can use for development purposes
3131

32-
## 5. Create new branch and rewrite code.
32+
## 5. Install pre-commit hooks
33+
$ uv tool install prek
34+
$ prek install
35+
36+
## 6. Create new branch and rewrite code.
3337
$ git checkout -b new-branch
3438

35-
## 6. Run unittest under Python 3.13 (you should pass all test and coverage should be 100%)
39+
## 7. Run unittest under Python 3.13 (you should pass all test and coverage should be 100%)
3640
$ tox run -e 3.13
3741

38-
## 7. Format and lint code (will print errors that cannot be automatically fixed)
42+
## 8. Format and lint code (will print errors that cannot be automatically fixed)
3943
$ tox run -e fix
4044

41-
## 8. Check README help text is up to date
45+
## 9. Check README help text is up to date
4246
$ tox run -e readme
4347

44-
## 9. Check CLI documentation is up to date
48+
## 10. Check CLI documentation is up to date
4549
$ tox run -e cli-docs
4650

47-
## 10. Commit and Push...
51+
## 11. Commit and Push...
4852
```
4953

5054
## ➕ Adding a New CLI Option
@@ -111,6 +115,9 @@ $ python scripts/build_cli_docs.py
111115

112116
# Verify docs are correct
113117
$ tox run -e cli-docs
118+
119+
# If you modified config.py, regenerate config TypedDicts
120+
$ tox run -e config-types
114121
```
115122

116123
### 🔧 Troubleshooting

0 commit comments

Comments
 (0)