description update

This commit is contained in:
2024-07-25 17:15:00 +01:00
parent 52ed87a967
commit ef0f3d76d2
17 changed files with 170 additions and 152 deletions

View File

@@ -24,6 +24,7 @@ class Website:
self.fetch_tags()
self.create_list()
self.build_about()
self.build_campfire()
self.fetch_all_images()
self.create_json('public/json/articles.json')
@@ -108,6 +109,12 @@ class Website:
with open(os.path.join('public', 'about.html'), 'w', encoding='utf8') as output_file:
output_file.write(html_output)
def build_campfire(self):
template = self.env.get_template('campfire.html')
html_output = template.render(
content=None
)
def format_content(self, content):
# convert all (link)(src) to <a> tags
content = re.sub(r'\(([^)]+)\)\[([^\]]+)\]', r'<a href="\2" target="_blank">\1</a>', content)