.PHONY: all clean tarot ED ?= ed # Items that are indented with additional spaces aren’t unpublished yet objects = index about 404 projects uses kpop \ checklist \ tripod \ design-for-exploitation \ this-post-is-lisp \ digital-bum \ hypertext \ making-c-uglier \ making-c-prettier \ this-post-is-cpp \ lambda-0 \ brainfuck-lessons \ lambda-1 \ regex-pronouns \ lisp-design-patterns \ nyxt-to-surf \ lambda-2 \ tui-not-tui \ falsehoods-html \ oop-c \ guile-optimization \ lambda-3 \ cl-is-lots \ my-generics \ gmi-a11y \ c-not-c \ prose-vs-tweet \ the-regex \ scrollbar \ disroot-gotcha \ wisp \ not-ai \ commitmsg \ printf \ procnames \ parameterized \ paren-regex \ sed-ed \ lisp-indent \ generated \ this-post-is-ed \ 3mins \ customize-ed \ codeberg-pages \ ugly-things \ lambda-4 \ css-only-highlight \ postmodern-front-end \ cutting-corners \ llms-suck \ tarot-biases \ transparent-ui \ lost-compute \ explanations \ lambda-5 \ stupid \ logical-pathnames \ customize-repl \ email-formatting \ just \ lisp-lines \ pidgin \ my-ed \ select-text \ threading \ advanc-ed \ lambda-6 \ customize-ed-2 \ atlas \ better-word \ blc-hard \ cl-submodules \ 2025 \ package-inferred \ boredom \ easy-fixes \ markdown \ computer-tenderness \ ed-1 \ ed-2 \ vscode-bad \ no-more-software \ re-prose \ kaktovik \ gess \ principles \ escalator html_objects = $(patsubst %, %.html, $(objects)) _html_only_objects = repl cv html_only_objects = $(patsubst %, %.html, $(_html_only_objects)) txt_objects = $(patsubst %, %.txt, $(objects)) man_objects = $(patsubst %, %.7, $(objects)) tex_objects = $(patsubst %, %.tex, $(objects)) pdf_objects = $(patsubst %, %.pdf, $(objects)) _tarot_objects = index \ satiated-death \ little-town-queen \ witness \ swords-x \ death \ cups-king \ pentacles-queen \ mirror tarot_objects = tarot/index.html $(patsubst %, tarot/stories/%.html, $(_tarot_objects)) clean: -rm $(html_objects) $(html_only_objects) \ $(txt_objects) \ $(man_objects) \ $(tex_objects) \ $(tarot_objects) \ *.aux *.log *.out *.nav *.snm *.toc \ */*.aux */*.log */*.out */*.nav */*.snm */*.toc \ $(pdf_objects) \ $(tarot_objects) tarot/index.html: tarot/index.htm -cp $^ $@ -$(ED) -s $@ < tarot/totarot.ed tarot: $(tarot_objects) html: $(html_objects) $(html_only_objects) txt: $(txt_objects) man: $(man_objects) latex: $(tex_objects) pdf: latex $(pdf_objects) all: html txt man latex tarot _redirects template_files = template/head template/header template/feedback template/footer template/copyright template/slide template/notebook template/nav %.txt: %.htm $(template_files) scripts/preprocess.ed scripts/totxt.ed -cp $< $@ -$(ED) -s $@ < scripts/preprocess.ed -$(ED) -s $@ < scripts/totxt.ed @echo $@ %.7: %.htm $(template_files) scripts/preprocess.ed scripts/toman.ed -cp $< $@ -$(ED) -s $@ < scripts/preprocess.ed -$(ED) -s $@ < scripts/toman.ed @echo $@ %.htm: %.phtm scripts/re-prose.ed -cp $< $@ -cat scripts/re-prose.ed | $(ED) -s $@ %.html: %.htm $(template_files) scripts/preprocess.ed scripts/tohtml.ed scripts/tohighlight.ed -cp $< $@ -$(ED) -s $@ < scripts/preprocess.ed -$(ED) -s $@ < scripts/tohtml.ed -$(ED) -s $@ < scripts/tohighlight.ed @echo $@ %.tex: %.htm $(template_files) scripts/preprocess.ed scripts/totex.ed -cp $< $@ -$(ED) -s $@ < scripts/preprocess.ed -$(ED) -s $@ < scripts/totex.ed @echo $@ %.pdf: %.tex -xelatex -interaction=batchmode -output-directory $(shell dirname $@) $^ %.all: %.html %.txt %.7 %.tex @echo "done" .PHONY: _redirects _redirects: _redirects.in $(html_objects) $(html_only_objects) cp _redirects.in _redirects $(foreach object,$(objects), echo "/$(object) /$(object).html 301" >> _redirects ;) $(foreach object,$(_html_only_objects), echo "/$(object) /$(object).html 301" >> _redirects ;)