diff options
author | Suleyman Farajli <suleyman@farajli.net> | 2025-02-13 00:46:31 +0400 |
---|---|---|
committer | Suleyman Farajli <suleyman@farajli.net> | 2025-02-13 00:46:31 +0400 |
commit | df719f8ecb135fafa13db27fb9a825019b22b71f (patch) | |
tree | 5f22e6056732fb6690ee053cc9f5a67e09680322 | |
parent | 3e564a8f8343801b04672fc0502d0f02d4ff5610 (diff) |
output html files style.css and favicon.ico into output/
-rw-r--r-- | .gitignore | 2 | ||||
-rw-r--r-- | BUGS | 2 | ||||
-rw-r--r-- | GNUmakefile | 16 |
3 files changed, 12 insertions, 8 deletions
@@ -1,2 +1,2 @@ install.mk -out/ +output/ @@ -1,3 +1,3 @@ - lists on mobile view has no margin -- Makefile html:md dependency is broken with the introduction of out/ directory ++ Makefile html:md dependency is broken with the introduction of out/ directory - Non-markdown files are not placed in the site (CV, Archive files, etc.) diff --git a/GNUmakefile b/GNUmakefile index c4a3766..dd66df7 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -1,13 +1,17 @@ -SRC := $(shell find . -name '*.md') -HTML = $(SRC:.md=.html) +SRC = $(shell find . -name '*.md') +HTML = $(patsubst ./%.md, %.html, $(SRC)) all: $(HTML) %.html: %.md build-page - mkdir -p out/$$(dirname $@) - sh build-page $< > out/$@ + sh build-page $< > $@ + +output: $(HTML) + echo $? | xargs -n 1 dirname | xargs -I _ mkdir -p $@/_ + echo $? | xargs -n 1 | xargs -I _ cp _ $@/_ + cp favicon.ico style.css $@/ clean: - rm -rf out/ + rm -rf $(HTML) output/ -.PHONY: all clean +.PHONY: all clean |