Update build scripts to pass flake8

This commit is contained in:
davemachado 2018-01-28 15:48:53 -05:00
parent e53982f9d1
commit 9eaf189595
5 changed files with 70 additions and 57 deletions

View file

@ -10,8 +10,8 @@ def markdown_to_json(filename, anchor):
entries = []
with open(filename) as fp:
lines = (line.rstrip() for line in fp)
lines = list(line for line in lines if line \
and line.startswith(anchor) or line.startswith('| '))
lines = list(line for line in lines if line and
line.startswith(anchor) or line.startswith('| '))
for line in lines:
if line.startswith(anchor):
category = line.split(anchor)[1].strip()
@ -45,5 +45,6 @@ def main():
anchor = sys.argv[2]
print(markdown_to_json(sys.argv[1], anchor))
if __name__ == "__main__":
main()