Skip to content

Commit de76334

Browse files
committed
Add flake8 and isort config
1 parent 58fd329 commit de76334

File tree

1 file changed

+58
-0
lines changed

1 file changed

+58
-0
lines changed

setup.cfg

+58
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
[flake8]
2+
max-line-length = 120
3+
# Following 4 for black compatibility
4+
# E501: line too long
5+
# W503: Line break occurred before a binary operator
6+
# E203: Whitespace before ':'
7+
# D202 No blank lines allowed after function docstring
8+
9+
# TODO fix flake8
10+
# D100 Missing docstring in public module
11+
# D101 Missing docstring in public class
12+
# D102 Missing docstring in public method
13+
# D103 Missing docstring in public function
14+
# D104 Missing docstring in public package
15+
# D105 Missing docstring in magic method
16+
# D107 Missing docstring in __init__
17+
# D200 One-line docstring should fit on one line with quotes
18+
# D205 1 blank line required between summary line and description
19+
# D209 Multi-line docstring closing quotes should be on a separate line
20+
# D400 First line should end with a period
21+
# D401 First line should be in imperative mood
22+
23+
ignore =
24+
E501,
25+
W503,
26+
E203,
27+
D202,
28+
29+
D100,
30+
D101,
31+
D102,
32+
D103,
33+
D104,
34+
D105,
35+
D107,
36+
D200,
37+
D205,
38+
D209,
39+
D400,
40+
D401,
41+
42+
[isort]
43+
# https://github.com/timothycrosley/isort
44+
# https://github.com/timothycrosley/isort/wiki/isort-Settings
45+
# splits long import on multiple lines indented by 4 spaces
46+
multi_line_output = 3
47+
include_trailing_comma=True
48+
force_grid_wrap=0
49+
use_parentheses=True
50+
line_length=88
51+
indent = " "
52+
# will group `import x` and `from x import` of the same module.
53+
force_sort_within_sections = true
54+
sections = FUTURE,STDLIB,THIRDPARTY,FIRSTPARTY,LOCALFOLDER
55+
default_section = THIRDPARTY
56+
known_first_party = custom_components,tests
57+
forced_separate = tests
58+
combine_as_imports = true

0 commit comments

Comments
 (0)