Lint script dev help (#840)
This commit is contained in:
parent
a53e6298db
commit
412fee43ad
1 changed files with 6 additions and 0 deletions
|
@ -41,6 +41,12 @@ $ pylint homeassistant/core.py
|
|||
$ py.test tests/test_core.py
|
||||
```
|
||||
|
||||
You also run linting tests against all changed files, as reported by `git diff upstream/dev --name-only` using the `lint` script:
|
||||
|
||||
```bash
|
||||
home-assistant$ script/lint --changed
|
||||
```
|
||||
|
||||
### {% linkable_title Prevent Linter Errors %}
|
||||
|
||||
You can save yourself the hassle of extra commits just to fix style errors by enabling the flake8 git commit hook. It will check your code when you attempt to commit to the repository. It will block the commit if there are any style issues, giving you a chance to fix it.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue