Skip to content

Commit

Permalink
style: add pre-commit hook for mypy
Browse files Browse the repository at this point in the history
  • Loading branch information
waza-ari committed Aug 19, 2024
1 parent 7cdaab2 commit 834e627
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 4 deletions.
4 changes: 4 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,7 @@ repos:
hooks:
- id: ruff
- id: ruff-format
- repo: https://github.com/pre-commit/mirrors-mypy
rev: 'v1.11.1'
hooks:
- id: mypy
14 changes: 10 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,11 +89,17 @@ EV_API_KEY=<your-api-key>
The client is written in pure Python, using `mkdocs` with `mkdocstrings` for documentation. Any changes or
pull requests are more than welcome, but please adhere to the code style:

- Use `black` for code formatting
- Use `isort` based import sorting
- Use `ruff` based code linting
- Use `ruff` based code linting, formatting and styling
- Use `mypy` for static type checking

A pre-commit hook configuration is supplied as part of the project.
A pre-commit hook configuration is supplied as part of the project. You can run them prior to your commit using:

```bash
pre-commit

# Or run them for the entire project
pre-commit run --all-files
```

Please make sure that any additions are properly tested. PRs won't get accepted if they don't have test cases to
cover them.
Expand Down

0 comments on commit 834e627

Please sign in to comment.