feat: storing languages
This commit is contained in:
parent
f6af26ef54
commit
948f3ca0ab
@ -94,28 +94,15 @@ def walk_directory(root):
|
||||
continue
|
||||
|
||||
if current_name.endswith(".md"):
|
||||
print(current_dst)
|
||||
convert_md(current_src, current_dst)
|
||||
language_codes_found.append(current_name.replace(".md", ""))
|
||||
|
||||
if current_src.is_dir():
|
||||
walk_directory(Path(root, current_full_path.name))
|
||||
|
||||
print(language_codes_found)
|
||||
|
||||
|
||||
def build():
|
||||
logger.info("building static page")
|
||||
|
||||
walk_directory("")
|
||||
return
|
||||
# copy_static()
|
||||
|
||||
context = Context()
|
||||
|
||||
# debug
|
||||
t = context.get_text({
|
||||
"content": """
|
||||
<h1 class="title">Hello World</h1>
|
||||
<p class="subtitle">My first website with <strong>Bulma</strong>!</p>
|
||||
"""
|
||||
})
|
||||
with Path(DIST_DIRECTORY, "index.html").open("w") as f:
|
||||
f.write(t)
|
||||
|
Loading…
x
Reference in New Issue
Block a user