mirror of
https://github.com/esphome/esphome-docs.git
synced 2025-01-26 22:21:38 +01:00
Remove whitespace at end of line and max line length check
Was getting too annoying, and only for asthetic purposes anyway.
This commit is contained in:
parent
ec75fa6027
commit
7a78abb560
14
travis.py
14
travis.py
@ -45,12 +45,6 @@ for f in sorted(Path('.').glob('**/*.rst')):
|
||||
|
||||
lines = content.splitlines(keepends=False)
|
||||
|
||||
# Check whitespace at end of line
|
||||
for i, line in enumerate(lines):
|
||||
if line.rstrip() != line:
|
||||
errors.append("Lines must not contain spaces at the end of the line. Please "
|
||||
"remove spaces at the end of {}:{}".format(f, i+1))
|
||||
|
||||
for i, line in enumerate(lines):
|
||||
if i == 0:
|
||||
continue
|
||||
@ -103,14 +97,6 @@ for f in sorted(Path('.').glob('**/*.rst')):
|
||||
"{}:{}".format(directive_name, num_indent, f, j+1))
|
||||
break
|
||||
|
||||
# Check line length
|
||||
for i, line in enumerate(lines):
|
||||
max_line_length = 160
|
||||
if len(line) > max_line_length:
|
||||
errors.append("Lines must not be longer than {} characters. Line {}:{} is {} "
|
||||
"characters long. Please insert newlines."
|
||||
"".format(max_line_length, f, i+1, len(line)))
|
||||
|
||||
for i, line in enumerate(lines):
|
||||
if esphome_io_regex.search(line):
|
||||
if 'privacy.rst' in str(f) or 'web_server.rst' in str(f):
|
||||
|
Loading…
Reference in New Issue
Block a user