tools: git output and pull fallback
[sheet.git] / Makefile
index 43323a15d08e1e59557e5607682e117bf4a54cc1..64e034bc5eab3c5e3cbb2a34b4b1215e6d937037 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -42,7 +42,8 @@ data/font/%.inc.pl: tools/mkttfinfo data/font/%.ttf
 
 data/xcolors/themes: data/xcolors
 data/xcolors:
-       [ -r $@/.git ] && cd $@ && git pull --ff-only
+       @echo git pull or clone $@
+       @[ -r $@/.git ] && cd $@ && git pull --ff-only || true
        @[ -e $@ ] || git clone https://github.com/tlatsas/xcolors $@
 
 data/termcol-xcolor.inc.pl: tools/mktermcol-xcolor data/xcolors/themes
@@ -94,7 +95,8 @@ data/browser: data/browser/support.inc.pl data/browser/usage-wm.inc.pl
 
 data/browser/caniuse/data.json: data/browser/caniuse
 data/browser/caniuse:
-       [ -r $@/.git ] && cd $@ && git pull --ff-only
+       @echo git pull or clone $@
+       @[ -r $@/.git ] && cd $@ && git pull --ff-only || true
        @[ -e $@ ] || git clone https://github.com/Fyrd/caniuse.git $@
 
 data/browser/support.inc.pl: tools/mkcaniuse data/browser/caniuse/data.json
@@ -117,6 +119,6 @@ clean:
 
 .SECONDEXPANSION:
 
-data/writing-latn.inc.pl: $$(@F)
-       perl -MData::Dumper -wE 'my @t = do "$<" or die $$@; print Data::Dumper->new([\@t])->Terse(1)->Quotekeys(0)->Indent(1)->Dump' | sponge $@
+data/writing-latn.inc.pl: tools/perlinc-static $$(@F)
+       $< $(word 2,$^) | sponge $@