From bfa0d2c61d31553f18733ed1e146d8d56039b3b5 Mon Sep 17 00:00:00 2001 From: EuAndreh Date: Fri, 18 Apr 2025 03:10:22 -0300 Subject: Makefile: Generate .gitignore and $(side-assets) list for symlinks --- Makefile | 25 +++++++++---------------- 1 file changed, 9 insertions(+), 16 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 23b7c00..454db65 100644 --- a/Makefile +++ b/Makefile @@ -176,13 +176,14 @@ derived-assets = \ src/content/.well-known/security.txt \ src/all-contents.txt \ src/all-filelists.txt \ + src/all-symlinks.txt \ src/install.txt \ src/sort-expected.txt \ src/sort-given.txt \ src/sources.txt \ install.txt \ sources.txt \ - redirect-symlinks.sentinel \ + src/content/.gitignore \ side-assets = \ src/collections/*/*/*/*/*.html.*.txt \ @@ -194,21 +195,11 @@ side-assets = \ src/collections/*/*.sortdata \ src/pages/*/*.html.*.txt \ src/content/.well-known/ \ + `cat src/all-symlinks.txt 2>/dev/null` \ src/content/css/ \ - src/content/en/favicon.ico \ src/content/favicon/ \ - src/content/static/ \ src/content/images/ \ - src/content/public.asc \ - src/content/public-key.txt \ - src/content/atom.xml \ - src/content/feed.xml \ - src/content/rss.xml \ - src/content/feed.atom \ - src/content/feed.en.atom \ - src/content/feed.blog.en.atom \ - src/content/feed.articles.en.atom \ - src/content/feed.til.en.atom \ + src/content/static/ \ @@ -222,9 +213,8 @@ $(derived-assets): Makefile deps.mk $(sources.conf): src/global.conf src/headers.txt -redirect-symlinks.sentinel: src/symlinks.txt - cd src/content/ && mkwb symlinks ../symlinks.txt - touch $@ +src/content/.gitignore: src/symlinks.txt + cd src/content/ && mkwb symlinks ../symlinks.txt > $(@F) src/dyn.conf: email.txt baseurl.txt fingerprint.txt printf "export url_pre='%s'\n" "`cat baseurl.txt`" > $@ @@ -314,6 +304,9 @@ src/all-contents.txt: src/all-filelists.txt: printf '%s\n' $(all-filelists) > $@ +src/all-symlinks.txt: src/content/.gitignore + sed 's|^|src/content|' src/content/.gitignore > $@ + src/install.txt: src/all-contents.txt src/all-filelists.txt $(all-filelists) cat src/all-contents.txt `cat src/all-filelists.txt` > $@ -- cgit v1.2.3