Skip to content

Instantly share code, notes, and snippets.

@JhoLee
Created August 12, 2020 07:41
Show Gist options
  • Save JhoLee/2a327fe13963ab067d08a5944bffd806 to your computer and use it in GitHub Desktop.
Save JhoLee/2a327fe13963ab067d08a5944bffd806 to your computer and use it in GitHub Desktop.
#!/bin/bash
BASE_URL="https://osmdata.openstreetmap.de/download/"
POSTFIX=".zip"
names=("simplified-water-polygons-split-3857" "water-polygons-split-3857" "antarctica-icesheet-polygons-3857" "antarctica-icesheet-outlines-3857")
for (( i=0; i<${#names[@]}; i++)); do
wget ${BASE_URL}${names[i]}${POSTFIX}
unzip ${names[i]}${POSTFIX}
rm ${names[i]}${POSTFIX}
mv ${names[i]}/* .
rm -r ${names[i]}
done
BASE_URL="https://www.naturalearthdata.com/http//www.naturalearthdata.com/download/110m/cultural/"
POSTFIX=".zip"
names=("ne_110m_admin_0_boundary_lines_land")
for (( i=0; i<${#names[@]}; i++)); do
wget ${BASE_URL}${names[i]}${POSTFIX}
unzip ${names[i]}${POSTFIX}
rm ${names[i]}${POSTFIX}
done
wget https://planet.openstreetmap.org/pbf/planet-latest.osm.pbf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment