Skip to content

Commit 945fb5c

Browse files
authored
Merge pull request #60 from OneZero-Y/docs/improve-contributing
docs: add pre-commit requirement code quality checks to contributing
2 parents 420f7bc + 8bd33ee commit 945fb5c

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

CONTRIBUTING.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ Thank you for your interest in contributing to the vLLM Semantic Router project!
1010
- [Running Tests](#running-tests)
1111
- [Development Workflow](#development-workflow)
1212
- [Code Style and Standards](#code-style-and-standards)
13+
- [Code Quality Checks](#code-quality-checks)
1314
- [Submitting Changes](#submitting-changes)
1415
- [Project Structure](#project-structure)
1516

@@ -191,6 +192,31 @@ The test suite includes:
191192

192193
## Code Style and Standards
193194

195+
### Code Quality Checks
196+
197+
Before submitting a PR, please run the pre-commit hooks to ensure code quality and consistency. **These checks are mandatory** and will be automatically run on every commit once installed.
198+
199+
**Step 1: Install pre-commit tool**
200+
```bash
201+
# Using pip (recommended)
202+
pip install pre-commit
203+
204+
# Or using conda
205+
conda install -c conda-forge pre-commit
206+
207+
# Or using homebrew (macOS)
208+
brew install pre-commit
209+
```
210+
211+
**Step 2: Install pre-commit hooks for this repository**
212+
```bash
213+
# Install pre-commit hooks
214+
pre-commit install
215+
216+
# Run all checks
217+
pre-commit run --all-files
218+
```
219+
194220
### Go Code
195221
- Follow standard Go formatting (`gofmt`)
196222
- Use meaningful variable and function names

0 commit comments

Comments
 (0)