measure and print how long notes generation takes
This commit is contained in:
parent
44bea9c982
commit
3a9cc4c0f8
7
gronk.py
7
gronk.py
@ -437,6 +437,8 @@ def generate_tag_browser(output_dir):
|
|||||||
def main(args):
|
def main(args):
|
||||||
""" Entry point for script """
|
""" Entry point for script """
|
||||||
|
|
||||||
|
start_time = time.time()
|
||||||
|
|
||||||
global LICENSE
|
global LICENSE
|
||||||
global FILEMAP
|
global FILEMAP
|
||||||
|
|
||||||
@ -465,7 +467,7 @@ def main(args):
|
|||||||
root_properties = FILEMAP.get(root)
|
root_properties = FILEMAP.get(root)
|
||||||
root_properties['dst_path']['raw'].mkdir(parents=True, exist_ok=True)
|
root_properties['dst_path']['raw'].mkdir(parents=True, exist_ok=True)
|
||||||
|
|
||||||
pprint.pprint(root_properties)
|
#pprint.pprint(root_properties)
|
||||||
html = JINJA_TEMPLATE_INDEX.render(
|
html = JINJA_TEMPLATE_INDEX.render(
|
||||||
gronk_commit=GRONK_COMMIT,
|
gronk_commit=GRONK_COMMIT,
|
||||||
title=root_properties.get('title', ''),
|
title=root_properties.get('title', ''),
|
||||||
@ -502,6 +504,9 @@ def main(args):
|
|||||||
generate_tag_browser(args.output_dir.joinpath('tags'))
|
generate_tag_browser(args.output_dir.joinpath('tags'))
|
||||||
generate_permalink_page(args.output_dir)
|
generate_permalink_page(args.output_dir)
|
||||||
|
|
||||||
|
elapsed_time = time.time() - start_time
|
||||||
|
print(f"generated notes {elapsed_time=}")
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user