Skip to content

Commit 9d9cd08

Browse files
committed
Now using black coding style
Enforcing via my flake8-black plugin, https://github.com/peterjc/flake8-black
1 parent b2c66da commit 9d9cd08

3 files changed

Lines changed: 16 additions & 4 deletions

File tree

.flake8

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
[flake8]
2+
3+
# Plugin flake8-black will pass this value to black
4+
max-line-length = 88
5+
6+
extend-ignore =
7+
# See https://github.com/PyCQA/pycodestyle/issues/373
8+
# flake8/pycodechecker give false positives on black code
9+
E203,

.travis.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,19 +20,19 @@ before_install:
2020
- "if grep '\t' *.py *.rst; then echo 'Tabs are bad, please use four spaces.'; false; fi"
2121
- "if grep -n -r '[[:blank:]]$' *.py *.rst; then echo 'Please remove trailing whitespace.'; false; fi"
2222
- pip install --upgrade pip setuptools
23-
- pip install flake8 flake8-docstrings restructuredtext-lint
24-
- echo "Using flake8 to check Python code"
23+
- pip install flake8 flake8-black flake8-docstrings restructuredtext-lint
24+
- echo "Using restructuredtext-lint to check documentation"
2525
- restructuredtext-lint *.rst
2626
- echo "Using flake8 to check Python code"
27-
- flake8 flake8_rst_docstrings.py
27+
- flake8 setup.py flake8_rst_docstrings.py
2828

2929
install:
3030
- python setup.py install
3131

3232
script:
3333
- echo "On this machine \$LANG=$LANG"
3434
- echo "Checking our own docstrings are valid RST"
35-
- flake8 --select RST flake8_rst_docstrings.py
35+
- flake8 --select RST setup.py flake8_rst_docstrings.py
3636
- echo "Checking we can parse our valid test cases"
3737
- flake8 --select RST --ignore RST303,RST304 tests/test_cases/*.py
3838

README.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ flake8-rst-docstrings
1010
.. image:: https://landscape.io/github/peterjc/flake8-rst-docstrings/master/landscape.svg?style=flat
1111
:alt: Landscape Code Metrics
1212
:target: https://landscape.io/github/peterjc/flake8-rst-docstrings/
13+
.. image:: https://img.shields.io/badge/code%20style-black-000000.svg
14+
:alt: Code style: black
15+
:target: https://github.com/ambv/black
1316

1417
Introduction
1518
------------

0 commit comments

Comments
 (0)