browser: caniuse data from github repository
authorMischa POSLAWSKY <perl@shiar.org>
Thu, 27 Apr 2017 01:44:14 +0000 (03:44 +0200)
committerMischa POSLAWSKY <perl@shiar.org>
Mon, 29 May 2017 17:21:21 +0000 (19:21 +0200)
Identical to downloaded json file but includes history and stuff.

Makefile

index 1fb2ac5..804bba7 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,7 @@
 all: digraphs.inc.pl unicode-cover.inc.pl countries.inc.pl data/browser/support.inc.pl termcol-xcolor.inc.pl
 more: all data/digraphs-xorg.inc.pl
 
-download: data/DerivedAge.txt data/rfc1345.txt data/xorg-compose data/countryInfo.txt data/caniuse.json
+download: data/DerivedAge.txt data/rfc1345.txt data/xorg-compose data/countryInfo.txt data/browser/caniuse
 .PHONY: download
 
 data/DerivedAge.txt:
@@ -82,10 +82,12 @@ data/countryInfo.txt:
 countries.inc.pl: tools/mkcountries-geonames data/countryInfo.txt
        $< $(word 2,$^) >$@
 
-data/caniuse.json:
-       tools/wget-ifmodified http://caniuse.com/data.json $@
+data/browser/caniuse/data.json: data/browser/caniuse
+data/browser/caniuse:
+       [ -r $@/.git ] && cd $@ && git pull --ff-only
+       @[ -e $@ ] || git clone https://github.com/Fyrd/caniuse.git $@
 
-data/browser/support.inc.pl: tools/mkcaniuse data/caniuse.json
+data/browser/support.inc.pl: tools/mkcaniuse data/browser/caniuse/data.json
        $< $(word 2,$^) >$@
 
 clean: