diff options
-rw-r--r-- | fetcher/.gitignore | 1 | ||||
-rwxr-xr-x | fetcher/fetch.sh | 9 |
2 files changed, 10 insertions, 0 deletions
diff --git a/fetcher/.gitignore b/fetcher/.gitignore new file mode 100644 index 0000000..8ee64a3 --- /dev/null +++ b/fetcher/.gitignore @@ -0,0 +1 @@ +f1db.sql* diff --git a/fetcher/fetch.sh b/fetcher/fetch.sh new file mode 100755 index 0000000..259cfc3 --- /dev/null +++ b/fetcher/fetch.sh @@ -0,0 +1,9 @@ +#!/bin/bash +pushd $(dirname $0) > /dev/null +wget -N http://ergast.com/downloads/f1db.sql.gz -q +if [[ f1db.sql.gz -nt f1db.sql ]] +then + echo "New ErgastDB version fetched" + zcat f1db.sql.gz | sed 's/ ENGINE=MyISAM//' > f1db.sql +fi +popd > /dev/null |