From 5993ec498c106a0b7a5e246f9bab612b459781cb Mon Sep 17 00:00:00 2001 From: Yax Date: Sun, 28 Sep 2025 11:47:18 +0200 Subject: [PATCH] Add TODO to externalize config some day... --- makesite.py | 27 ++------------------------- 1 file changed, 2 insertions(+), 25 deletions(-) diff --git a/makesite.py b/makesite.py index a8e30b5..8ebab89 100755 --- a/makesite.py +++ b/makesite.py @@ -1,30 +1,5 @@ #!/usr/bin/env python3 -# The MIT License (MIT) -# -# Copyright (c) 2018 Sunaina Pai -# -# Permission is hereby granted, free of charge, to any person obtaining -# a copy of this software and associated documentation files (the -# "Software"), to deal in the Software without restriction, including -# without limitation the rights to use, copy, modify, merge, publish, -# distribute, sublicense, and/or sell copies of the Software, and to -# permit persons to whom the Software is furnished to do so, subject to -# the following conditions: -# -# The above copyright notice and this permission notice shall be -# included in all copies or substantial portions of the Software. -# -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -# IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -# CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -# TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -# SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -# Modifed by Yax - """Make static website/blog with Python.""" import argparse @@ -168,6 +143,8 @@ def read_content(filename, params): def fix_relative_links(site_url, text): + """Absolute links needed in RSS feed""" + # TODO externalize links replacement configuration return text \ .replace("src=\"/images/20", "src=\"" + site_url + "/images/20") \ .replace("href=\"/20", "href=\"" + site_url + "/20")