Format some long lines.
This commit is contained in:
parent
e0974f87ac
commit
b14a06c1eb
2 changed files with 8 additions and 5 deletions
|
@ -98,7 +98,11 @@ class Article:
|
|||
def __str__(self):
|
||||
return f'Article({self.md_file.absolute_path})'
|
||||
|
||||
ARTICLES = {file: Article(file) for file in spinal.walk_generator(writing_rootdir) if file.extension == 'md' and file.parent != writing_rootdir}
|
||||
ARTICLES = {
|
||||
file: Article(file)
|
||||
for file in spinal.walk_generator(writing_rootdir)
|
||||
if file.extension == 'md' and file.parent != writing_rootdir
|
||||
}
|
||||
|
||||
def write_articles():
|
||||
for article in ARTICLES.values():
|
||||
|
@ -298,4 +302,4 @@ complete_tag_index = Index()
|
|||
all_tags = set(P.get_tags())
|
||||
permute(tuple(), all_tags)
|
||||
write_tag_pages()
|
||||
write_writing_index()
|
||||
write_writing_index()
|
||||
|
|
|
@ -541,7 +541,6 @@ def markdown(
|
|||
if do_embed_images:
|
||||
embed_images(soup, cache=image_cache)
|
||||
|
||||
|
||||
if return_soup:
|
||||
return soup
|
||||
|
||||
|
@ -592,8 +591,8 @@ def markdown_flask(core_filename, port, *args, **kwargs):
|
|||
html = markdown(md=cat_file(filename), *args, **kwargs)
|
||||
refresh = request.args.get('refresh', None)
|
||||
if refresh is not None:
|
||||
refresh = max(float(refresh), 1)
|
||||
html += f'<script>setTimeout(function(){{window.location.reload()}}, {refresh * 1000})</script>'
|
||||
refresh = 1000 * max(float(refresh), 1)
|
||||
html += f'<script>setTimeout(function(){{window.location.reload()}}, {refresh})</script>'
|
||||
return html
|
||||
|
||||
@site.route('/')
|
||||
|
|
Loading…
Reference in a new issue