Commit 47479f34 authored by Lubomir Prda's avatar Lubomir Prda

corrections to python scripts

parent 7f33b4e5
......@@ -35,7 +35,7 @@ def main(location):
disabled = 0
if line.startswith('#') and disabled == 0:
line = titlecase(line[:(line.find("]"))], callback=abbreviations)+line[(line.find("]")):]
if line.startswith('---') or line.startswith('==='):
if (line.startswith('---') or line.startswith('===')) and disabled == 0:
prev_line = titlecase(prev_line[:(prev_line.find("]"))], callback=abbreviations)+prev_line[(prev_line.find("]")):]
f.write(prev_line)
prev_line = line
......
......@@ -41,7 +41,7 @@ def main(location):
print("-"+line,end="")
print("+"+titlecase(line[:(line.find("]"))], callback=abbreviations)+line[(line.find("]")):],end="")
return_value = 1
if line.startswith('---') or line.startswith('==='):
if (line.startswith('---') or line.startswith('===')) and disabled == 0:
if prev_line != titlecase(prev_line[:(prev_line.find("]"))], callback=abbreviations)+prev_line[(prev_line.find("]")):]:
print()
print("-"+prev_line,end="")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment