diff --git a/scripts/blog b/scripts/blog
index 197946f..0c8f71c 100755
--- a/scripts/blog
+++ b/scripts/blog
@@ -61,7 +61,7 @@ DEFAULT_CONFIG_FILE: str = "blog.json"
HISTORY_FILE: str = ".blog_history"
BLOG_VERSION: int = 1
-BLOG_MARKDOWN_TEMPLATE = """# %s
+BLOG_MARKDOWN_TEMPLATEL: str = """# %s
%s |
back |
home |
git
@@ -71,7 +71,7 @@ BLOG_MARKDOWN_TEMPLATE = """# %s
%s"""
-HTML_HEADER = """
+HTML_HEADER: str = """
@@ -86,7 +86,7 @@ HTML_HEADER = """
"""
-BLOG_HTML_TEMPLATE = f"""
+BLOG_HTML_TEMPLATE: str = f"""
{HTML_HEADER}
@@ -98,7 +98,7 @@ BLOG_HTML_TEMPLATE = f"""
"""
-HOME_PAGE_HTML_TEMPLATE = f"""
+HOME_PAGE_HTML_TEMPLATE: str = f"""
{HTML_HEADER}
@@ -215,6 +215,8 @@ def new_blog(config: Dict) -> Tuple[int, Dict]:
with open(file, "r") as md:
blog["content"] = b64encode(md.read().encode()).decode()
+ os.remove(file)
+
if not blog["content"].strip(): # type: ignore
return log("Blog cannot be empty"), config