forked from GitHub/gf-rgl
Use Pandoc and introduce HTML template for synopsis
- Remove isLatex flag - Plan to convert to Markdown and simply format
This commit is contained in:
16
doc/Makefile
16
doc/Makefile
@@ -24,9 +24,23 @@ SRC_FILES=$(S)/abstract/Common.gf $(S)/abstract/Cat.gf $(S)/api/Constructors.gf
|
||||
EXAMPLES_OUT=$(patsubst %,api-examples-%.txt,$(LANGS))
|
||||
INCLUDES=synopsis-intro.txt categories-intro.txt categories-imagemap.html synopsis-additional.txt synopsis-browse.txt synopsis-example.txt
|
||||
|
||||
synopsis.html: MkSynopsis.hs MkExxTable.hs $(INCLUDES) $(EXAMPLES_OUT) $(SRC_FILES)
|
||||
synopsis.txt: MkSynopsis.hs MkExxTable.hs $(INCLUDES) $(EXAMPLES_OUT) $(SRC_FILES)
|
||||
runghc -i.. MkSynopsis.hs
|
||||
|
||||
TMP=tmp.html
|
||||
synopsis.html: synopsis.txt
|
||||
txt2tags --target=html --no-headers --quiet --toc --outfile=$@ --infile=$^
|
||||
pandoc \
|
||||
--from=html \
|
||||
--to=html5 \
|
||||
--standalone \
|
||||
--template=_template.html \
|
||||
--metadata='title:"GF Resource Grammar Library: Synopsis"' \
|
||||
--variable='rel-root:../..' \
|
||||
--output=$(TMP) \
|
||||
$@
|
||||
mv $(TMP) $@
|
||||
|
||||
categories.png: categories.dot
|
||||
dot -Tpng $^ > $@
|
||||
|
||||
|
||||
Reference in New Issue
Block a user