support fetchall feature

This commit is contained in:
Jean-Marie Renouard 2019-09-30 20:35:09 +02:00
parent fedc925111
commit ad8b04b6a4

View file

@ -13,11 +13,18 @@ getVal()
eval "echo \$$vari"
}
case "$1" in
"fetchall")
for sample in WORLD WORLDX SAKILA MESSAGERIE TESTDB; do
sh $0 fetch $sample
done
;;
"fetch")
[ -z "$2" ] && exit 1
mkdir -p ./contents
wget -O contents/$(basename $(getVal "DB_$2_URL")) $(getVal "DB_$2_URL")
;;
"load")
;;
*)
echo "Unknown operation: $1"