horribelt og ulæseligt
This commit is contained in:
parent
a89c213ef8
commit
a28f76e394
12
Makefile
12
Makefile
|
@ -7,15 +7,19 @@ files := $(wildcard org/*.org)
|
|||
all: org html pdf tex
|
||||
|
||||
org html pdf tex : $(wildcard org/*.org)
|
||||
GOALS=`echo $(files) | sed 's/\.org/.$@/g' | sed 's/org\//out\//g'`; \
|
||||
GOALS=`echo $(foreach file,$(files),out/$(basename $(notdir $(file)))/$(notdir $(file))) | sed 's/\.org/.$@/g'`; \
|
||||
$(MAKE) $$GOALS;
|
||||
|
||||
out tmp :
|
||||
mkdir $@
|
||||
|
||||
.SECONDEXPANSION:
|
||||
out/%.org out/%.tex out/%.pdf out/%.html : $$(subst out,tmp,$$@) | out
|
||||
cp $< out/
|
||||
out/%.org out/%.tex out/%.pdf out/%.html : tmp/$$(notdir $$@) | out
|
||||
mkdir -p $(@D)
|
||||
echo $@
|
||||
echo out/$(basename $(notdir $@))
|
||||
echo $(notdir $@) out/$(basename $(notdir $<)) $<
|
||||
cp $< out/$(basename $(notdir $<))
|
||||
|
||||
tmp/%.org : org/%.org | tmp
|
||||
cp $< tmp/
|
||||
|
@ -38,4 +42,4 @@ upload:
|
|||
scp -P 35284 out/* christoffer@users.guava.space:public_html/holdets_time/
|
||||
|
||||
publish:
|
||||
cp out/* ~/public_html/holdets_time/
|
||||
cp -r out/* ~/public_html/holdets_time/
|
||||
|
|
Loading…
Reference in New Issue
Block a user