-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
32 lines (25 loc) · 839 Bytes
/
Makefile
File metadata and controls
32 lines (25 loc) · 839 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# Default course language
CLANG?=el
HTMLDIR?=$(UH)/dds/pubs/web/home/ba
DISTDIR?=/cygdrive/d/pres
TARGETS=$(shell sed -n 's|<li><a href="\([^"]*\)">.*|$(HTMLDIR)/\1|p' index-$(CLANG).html)
INDEX=$(HTMLDIR)/index.html
.SUFFIXES:.html .md
$(HTMLDIR)/%.html: %.md
( cat head1-$(CLANG).html ; \
sed -n 's|<li><a href="$(@F)">\([^<]*\)<.*|<title>\1<\/title>|p' index-$(CLANG).html ; \
cat head2-$(CLANG).html ; \
sed -n 's|<li><a href="$(@F)">\([^<]*\)<.*|## \1|p' index-$(CLANG).html ; \
cat title-$(CLANG).md ; \
cat $< ; \
cat tail-$(CLANG).html ) >$@
all: $(TARGETS) $(INDEX)
cp -ru a $(HTMLDIR)/
$(INDEX): index-$(CLANG).html
cp $< $@
clean:
rm -f $(TARGETS)
dist: $(TARGETS)
test -r $P.md
cp $(HTMLDIR)/$P.html $(DISTDIR)
echo "file:/boot/pres/$P.html" >$(DISTDIR)/../kiosk