This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Extract the US zip-code shapes and convert to a single US-wide | |
# GeoJSON file | |
echo -n "Extracting US-wide GeoJSON file (takes ~10 mins)..." | |
mkdir tl_2014_us_zcta510 | |
unzip -qq tl_2014_us_zcta510.zip -d tl_2014_us_zcta510 | |
ogr2ogr -f GeoJSON -t_srs crs:84 tl_2014_us_zcta510.geojson tl_2014_us_zcta510/tl_2014_us_zcta510.shp | |
rm -r tl_2014_us_zcta510 | |
echo "done." |