aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorDenis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>2024-05-09 19:15:54 +0200
committerDenis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>2025-06-15 01:30:29 +0200
commit731ddadbb5760c3ee5619c493d856374b4bea16d (patch)
tree9ff7c19c867380c4315e5c41fedc415169fd4c21 /Makefile
parent3e21e8873ea1f47c117fcd80fbf6d98c66aea17b (diff)
downloadhaunt-blog-731ddadbb5760c3ee5619c493d856374b4bea16d.tar.gz
haunt-blog-731ddadbb5760c3ee5619c493d856374b4bea16d.tar.bz2
haunt-blog-731ddadbb5760c3ee5619c493d856374b4bea16d.zip
Makefile: move scheme code in build/
Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile40
1 files changed, 1 insertions, 39 deletions
diff --git a/Makefile b/Makefile
index bdd87d5..706de07 100644
--- a/Makefile
+++ b/Makefile
@@ -40,45 +40,7 @@ SENTINEL =
update-makefile \
$(SENTINEL)
-# Input: wordpress/articles/2015_07_replicant-source-code-hosting-and-rmll-2015.html
-# Output: https://blog.replicant.us/2015/07/replicant-source-code-hosting-and-rmll-2015/
-define get-wordpress-article-url
-
-(use-modules (ice-9 regex))
-
-;; Input: wordpress/articles/2015_07_replicant-source-code-hosting-and-rmll-2015.html
-;; Output: 2015_07_replicant-source-code-hosting-and-rmll-2015.html
-(define (local-filename name)
- (list-ref (string-split name #\/) 2))
-
-;; Output: 2015
-(define year
- (car (string-split (local-filename "$@") #\_)))
-
-;; Output: 07
-(define month
- (cadr (string-split (local-filename "$@") #\_)))
-
-;; Output: replicant-source-code-hosting-and-rmll-2015.html
-(define html-page
- (regexp-substitute
- #f
- (string-match
- "[0-9]{4}_[0-9]{2}_"
- "$@")
- 'post))
-
-;; Output: replicant-source-code-hosting-and-rmll-2015
-(define page-path
- (regexp-substitute
- #f
- (string-match
- ".html"
- html-page)
- 'pre))
-
-(string-append "https://blog.replicant.us/" year "/" month "/" page-path "/")
-endef
+include build/get-wordpress-article-url.scm
WORDPRESS_PAGES = \
wordpress/pages/replicant_blog_page_8.html \