From 2bbcd8433284dd24154654e1d6bb61d6bb2e4c63 Mon Sep 17 00:00:00 2001 From: Erich Eckner Date: Tue, 15 May 2018 09:06:00 +0200 Subject: convert: make target area configurable --- convert | 51 ++++++++++++++++++++++++++++++++++++++------------- 1 file changed, 38 insertions(+), 13 deletions(-) (limited to 'convert') diff --git a/convert b/convert index 75598f6..e9fb673 100755 --- a/convert +++ b/convert @@ -9,19 +9,44 @@ then fi mainUrl='https://download.geofabrik.de/europe/' -countries=( - austria - belgium - croatia - czech-republic - germany - italy - luxembourg - netherlands - poland - slovakia - slovenia -) + +case "$1" in + '') + countries=( + austria + germany + italy + switzerland + ) + ;; + 'benelux') + countries=( + belgium + luxembourg + netherlands + ) + ;; + 'fast') + mainUrl="${mainUrl}germany/" + countries=( + thueringen + ) + ;; + 'gus') + countries=( + croatia + czech-republic + poland + slovakia + slovenia + ) + ;; + *) + >&2 printf 'Unknown option "%s".\n' "$1" + exit 1 + ;; +esac + numJobs=$(($(/usr/bin/getconf _NPROCESSORS_ONLN)/2)) if [ ${numJobs} -lt 1 ] then -- cgit v1.2.3-70-g09d2