Get GeoJSON by choosing categories & subcategories on the command line. Choose a file and it's instantly downloaded.
Or supply a bit of a filename, like ocean
or rail
, and a fuzzy
search magically guesses which file you want, and downloads it for you.
npm install -g geojson-xyz
After installing, just run geojson-xyz
.
All praise to Natural Earth Data as the source of the majority of the data exposed in this interface. This is mostly a different way to access that data.
To fuzzy-match in realtime, you can install fzf and then:
geojson-xyz --list | fzf | xargs wget
Or xargs whatever you want at the end of that. fzf will let you filter the list however you want and pipe your choice to the next step.
Running
geojson-xyz airports -
Means "fuzzy-match airports and output results to stdout". You can substitute
anything else for 'airports'. Outputting to stdout means you can pipe that
GeoJSON places - for instance, if you have geojsonio-cli
installed, pipe it to geojsonio
!