monochromatic

monochromatic blog: http://blog.z3bra.org
git clone git://z3bra.org/monochromatic
Log | Files | Refs

Makefile (613B)


      1 include config.mk
      2 
      3 .PHONY: all check clean
      4 
      5 all: $(PAGES) $(FEEDS) $(EXTRA)
      6 
      7 $(NAME).tbz: $(PAGES) $(EXTRA) $(FEEDS)
      8 	tar -cvjf $@ $(PAGES) $(EXTRA) $(FEEDS)
      9 
     10 $(EXTRA):
     11 	mkdir -p $@
     12 
     13 install: $(NAME).tbz
     14 	mkdir -p $(PREFIX)
     15 	tar -xjf $(NAME).tbz -C $(PREFIX)
     16 
     17 check: $(PAGES)
     18 	@./check.sh
     19 
     20 clean:
     21 	rm -f $(PAGES) $(FEEDS) $(NAME).tbz
     22 
     23 .SUFFIXES: .txt .html .xml
     24 
     25 HEADER = head.html
     26 FOOTER = foot.html
     27 
     28 $(FEEDS): index.txt
     29 	@echo "RSSGEN $@"
     30 	@mkdir -p `dirname $(FEEDS)`
     31 	@./feeds.sh index.txt > $(FEEDS)
     32 
     33 .txt.html: $(HEADER) $(FOOTER)
     34 	@echo "MARKDOWN `basename $@`"
     35 	@$(MD) $< | cat $(HEADER) - $(FOOTER) > $@