Skip to content

Commit 70a6a80

Browse files
committed
Use wildcard names
1 parent e0b5d6e commit 70a6a80

File tree

1 file changed

+4
-8
lines changed

1 file changed

+4
-8
lines changed

geonames_importer.sh

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -47,14 +47,10 @@ download_geonames_data() {
4747
for zip in $zip_codes; do
4848
wget -c -O "${zip:0:(-4)}_zip.zip" http://download.geonames.org/export/zip/$zip
4949
done
50-
unzip allCountries.zip
51-
unzip alternateNames.zip
52-
unzip hierarchy.zip
53-
unzip allCountries_zip.zip -d ./zip/
54-
rm allCountries.zip
55-
rm alternateNames.zip
56-
rm hierarchy.zip
57-
rm allCountries_zip.zip
50+
unzip "*_zip.zip" -d ./zip
51+
rm *_zip.zip
52+
unzip "*.zip"
53+
rm *.zip
5854
}
5955

6056
if [ $# -lt 1 ]; then

0 commit comments

Comments
 (0)