about summary refs log tree commit diff stats
path: root/wip/makefile
diff options
context:
space:
mode:
authorCase Duckworth2015-04-01 16:29:46 -0700
committerCase Duckworth2015-04-01 16:29:46 -0700
commit61baf210a9d0d4fffcd82751ba3419dd2feb349d (patch)
tree577fe121f035854399f820c420eca38b60879156 /wip/makefile
parentAdd Abstract and Process Narrative (diff)
downloadautocento-61baf210a9d0d4fffcd82751ba3419dd2feb349d.tar.gz
autocento-61baf210a9d0d4fffcd82751ba3419dd2feb349d.zip
Revise a few poems in Elegies
Also add a .gitignore.  How is this so late?
Diffstat (limited to 'wip/makefile')
-rw-r--r--wip/makefile48
1 files changed, 48 insertions, 0 deletions
diff --git a/wip/makefile b/wip/makefile new file mode 100644 index 0000000..88ff6c9 --- /dev/null +++ b/wip/makefile
@@ -0,0 +1,48 @@
1# MAKEFILE for Autocento of the breakfast table
2# by Case Duckworth | case.duckworth@gmail.com | autocento.me
3# inspired by Lincoln Mullen | lincolnmullen.com
4# vim: fdm=marker
5
6# Define variables {{{
7srcs := $(wildcard *.txt)
8trunk:= trunk
9versifyer = $(trunk)/versify.exe
10versifySrc= $(trunk)/versify.hs
11
12htmlBlackList = index.html template.html index-txt.html
13htmls = $(filter-out $(htmlBlackList),$(patsubst %.txt,%.html,$(srcs)))
14htmlTemplate = template.html
15htmlPandocOptions = --template=$(htmlTemplate)
16htmlPandocOptions+= --filter=$(versifyer)
17htmlPandocOptions+= --smart --mathml --section-divs
18
19backBlackList = "hapax.txt|first-lines.txt|common-titles.txt"
20backSrcs = $(patsubst %.html,%.back,$(htmls))
21backs = $(patsubst %.back, %_backlinks.htm,$(backSrcs))
22backHead = $(trunk)/backlink.head
23
24hapaxBlackList = first-lines.txt common-titles.txt hapax.txt
25hapaxs = $(patsubst %.txt,%.hapax,$(srcs))
26hapaxer = $(trunk)/hapax.lua
27hapaxHead = $(trunk)/hapax.head
28hapaxTemp = hapax.tmp
29hapaxOut = hapax.txt
30
31lozengeOut = $(trunk)/lozenge.js
32# }}}
33
34.PHONY: all
35all: $(versifyer) htmls backlinks
36.PHONY: htmls
37htmls: $(htmls)
38.PHONY: backlinks
39backlinks: $(backs)
40
41$(versifyer): $(versifySrc)
42 ghc --make $(versifySrc)
43
44%.html: %.txt template.html $(versifyer)
45 pandoc $< -f markdown -t html5 $(htmlPandocOptions) -o $@
46
47%_backlinks.htm: %.back
48 pandoc $< -f markdown -t html5 $(htmlPandocOptions) -o $@