]> mj.ucw.cz Git - ga.git/commitdiff
Opraveno sesazování celé knihy
authorMartin Mares <mj@ucw.cz>
Sat, 13 Jan 2024 14:42:24 +0000 (15:42 +0100)
committerMartin Mares <mj@ucw.cz>
Sat, 13 Jan 2024 14:42:24 +0000 (15:42 +0100)
all/Makefile
all/preprocess

index 775a5f1dce9d085c11e398ceb4dc1bf3331a4c47..dcaf462ce83e2ce985c26790d5d0072312e79433 100644 (file)
@@ -1,16 +1,21 @@
 P=ga
-X=$(shell for a in 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 ; do echo ../$$a-*/$$a-*.tex ; done)
+CHAP=0 1 2 3 4 5 6 7 8 9 10 11 12 13 14
+CHAPTERS=$(shell for a in $(CHAP) ; do echo ../$$a-* ; done)
+X=$(shell for a in $(CHAP) ; do echo ../$$a-*/$$a-*.tex ; done)
 
 universe: all
 
 CUSTOM_UPLOAD=1
 include ../Makerules
 
-ga.pdf: ga.tex body.tex
+ga.pdf: ga.tex body.tex chapters
 
 body.tex: $(X) preprocess
        ./preprocess $(X) >$@
 
+chapters:
+       for chap in $(CHAPTERS) ; do make -C $$chap ; done
+
 clean::
        rm -f body.tex
 
index 4b8b7b3ba5e3c34e0dcb4144bb34ed7d13c99cf1..58c512a81bf238eff6a712cb89b92d0c068a6e27 100755 (executable)
@@ -11,7 +11,8 @@ foreach my $f (@ARGV) {
                /^\\input .*sgr\.tex/ && next;
                /^\\references/ && next;
                /^\\bye/ && last;
-               s@\\(figure|fig|inlinefig|epsfbox){([^}]+)}@\\$1\{$d$2}@g;
+               s@\\(putepdf){([^}]*)}{([^}]+)}@\\$1\{$2}\{$d$3}@g;
+               s@\\(figure|fig|inlinefig){([^}]+)}@\\$1\{$d$2}@g;
                s@\\(twofigures)\{([^}]+)}(\{[^}]+}\{[^}]+})\{([^}]+)}@\\$1\{$d$2}$3\{$d$4}@g;
                print;
        }