-
Notifications
You must be signed in to change notification settings - Fork 98
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #102 from sloria/black
Use black and pre-commit
- Loading branch information
Showing
24 changed files
with
962 additions
and
745 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
repos: | ||
- repo: https://github.com/ambv/black | ||
rev: 18.9b0 | ||
hooks: | ||
- id: black | ||
exclude: docopt.py | ||
language_version: python3.6 | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: v2.0.0 | ||
hooks: | ||
- id: flake8 | ||
- repo: https://github.com/asottile/blacken-docs | ||
rev: v0.3.0 | ||
hooks: | ||
- id: blacken-docs | ||
additional_dependencies: [black==18.9b0] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
# Contributing | ||
|
||
## Setting up for development | ||
|
||
* Create and activate a new virtual environment | ||
* `pip install -e '.[dev]'` | ||
* (Optional but recommended) If you're using a Python 3.6 virtual | ||
environment, install the pre-commit hooks, which will | ||
format and lint your git staged files: | ||
|
||
|
||
``` | ||
# The pre-commit CLI was installed above | ||
pre-commit install | ||
``` | ||
|
||
* To run tests: | ||
|
||
``` | ||
pytest | ||
``` | ||
|
||
* To run syntax checks: | ||
|
||
``` | ||
tox -e lint | ||
``` | ||
|
||
* To build the docs: | ||
|
||
``` | ||
tox -e watch-docs | ||
``` | ||
|
||
* (Optional) To run tests on Python 2.7, 3.5, 3.6, and 3.7 virtual environments (must have each interpreter installed): | ||
|
||
``` | ||
tox | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
__version__ = '4.2.1' | ||
__version__ = "4.2.1" |
Oops, something went wrong.