diff --git a/Gmeek.py b/Gmeek.py index d79fae9..80ed285 100644 --- a/Gmeek.py +++ b/Gmeek.py @@ -74,14 +74,13 @@ class GMEEK(): os.mkdir(self.post_dir) if os.path.exists(self.static_dir): - target_static_dir = os.path.join(self.root_dir, 'static') - shutil.copytree(self.static_dir, target_static_dir) + shutil.copytree(self.static_dir, os.path.join(self.root_dir, 'static')) print("Copy static to docs") else: print("static not exist") def defaultConfig(self): - dconfig={"singlePage":[],"startSite":"","filingNum":"","onePageListNum":15,"commentLabelColor":"#006b75","yearColorList":["#bc4c00", "#0969da", "#1f883d", "#A333D0"],"i18n":"CN","themeMode":"manual","dayTheme":"light","nightTheme":"dark","urlMode":"pinyin","script":"","style":"","indexScript":"","indexStyle":"","bottomText":"","showPostSource":1,"iconList":{},"UTC":+8,"rssSplit":"sentence","exlink":{}} + dconfig={"singlePage":[],"startSite":"","filingNum":"","onePageListNum":15,"commentLabelColor":"#006b75","yearColorList":["#bc4c00", "#0969da", "#1f883d", "#A333D0"],"i18n":"CN","themeMode":"manual","dayTheme":"light","nightTheme":"dark","urlMode":"pinyin","script":"","style":"","indexScript":"","indexStyle":"","bottomText":"","showPostSource":1,"iconList":{},"UTC":+8,"rssSplit":"sentence","exlink":{},"needComment":1} config=json.loads(open('config.json', 'r', encoding='utf-8').read()) self.blogBase={**dconfig,**config}.copy() self.blogBase["postListJson"]=json.loads('{}') diff --git a/templates/post.html b/templates/post.html index 6676904..e60270e 100644 --- a/templates/post.html +++ b/templates/post.html @@ -57,8 +57,10 @@ {% block content %}