something
This commit is contained in:
parent
9800b08204
commit
a1217c872a
|
@ -149,10 +149,11 @@ for page_dict in config.custom_pages:
|
||||||
rel_path, filename = os.path.split(page_dict["name"])
|
rel_path, filename = os.path.split(page_dict["name"])
|
||||||
if rel_path:
|
if rel_path:
|
||||||
os.makedirs(rel_path, exist_ok=True)
|
os.makedirs(rel_path, exist_ok=True)
|
||||||
basename, extension = os.path.splitext(page_dict["name"])
|
basename, extension = os.path.splitext(filename)
|
||||||
if not extension:
|
if extension = "":
|
||||||
extention = config.gmi_extension
|
filename = basename + config.gmi_extension
|
||||||
filename = basename + extension
|
else:
|
||||||
|
filename = basename + extension
|
||||||
filepath = os.path.join(rel_path, filename)
|
filepath = os.path.join(rel_path, filename)
|
||||||
with open(tpl_path + "/" + page_dict.get("tpl", basename) + ".tpl", "r") as tpl:
|
with open(tpl_path + "/" + page_dict.get("tpl", basename) + ".tpl", "r") as tpl:
|
||||||
template = Template(tpl.read())
|
template = Template(tpl.read())
|
||||||
|
|
Loading…
Reference in New Issue