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 | |
# ref: https://github.com/data61/gnaf/blob/master/gnaf-db/src/main/script/createGnafDb.sh | |
# input dir | |
DATA_DIR="/data/gnaf/G-NAF/G-NAF AUGUST 2021" | |
EXTRAS_DIR="/data/gnaf/G-NAF/Extras" | |
# fast import pragmas | |
echo '.output /dev/null' | |
echo 'PRAGMA main.foreign_keys=OFF;' |
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
85632505|meso|0|Self-intersection[-69.31 -28.27]|POINT(-69.31 -28.27) | |
85632793|quattroshapes-reversegeo|-1|| | |
85632793|quattroshapes|-1|| | |
85681583||0|Self-intersection[144.652483533911 -40.3811760786903]|POINT(144.652484 -40.381176) | |
85770383|quattroshapes|0|Ring Self-intersection[147.317205739621 -42.9812372030377]|POINT(147.317206 -42.981237) | |
85775753|quattroshapes|0|Ring Self-intersection[150.501708984 -23.3725138223999]|POINT(150.501709 -23.372514) | |
85781949|quattroshapes|0|Ring Self-intersection[117.927246094 -35.0344943317]|POINT(117.927246 -35.034494) | |
85632475|meso|0|Self-intersection[88.906686 22.921783]|POINT(88.906686 22.921783) | |
85801287|quattroshapes|0|Ring Self-intersection[4.47143554686997 50.8891740489]|POINT(4.471436 50.889174) | |
85929283|quattroshapes|0|Ring Self-intersection[23.3294677734 42.6622413763001]|POINT(23.329468 42.662241) |
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
# based on: https://s2geometry.io/about/platforms | |
# note: set -DOPENSSL_ROOT_DIR instead of -DOPENSSL_INCLUDE_DIR | |
brew install gflags glog openssl | |
brew install cmake | |
# Download Googletest release 1.8.0 and unpack it in a directory of your choosing. | |
# (Take note of this directory as you will need to point CMake to it.) | |
# https://github.com/google/googletest/releases/tag/release-1.8.0 |
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 | |
featureCollectionSandwich() { | |
echo '{ "type": "FeatureCollection", "features":' | |
cat - | jq -s . | |
echo '}' | |
} |
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
const interval = { | |
millisecond: 1, | |
second: 1000, | |
minute: 1000 * 60, | |
hour: 1000 * 60 * 60, | |
day: 1000 * 60 * 60 * 24 | |
} | |
const period = 'day' | |
const d1 = truncate(new Date('2020-01-01 22:22:22'), period) |
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
var m = [ | |
[' ',' ',' ',' ',' '], | |
[' ',' ',' ',' ',' '], | |
['X',' ',' ',' ',' '], | |
[' ','X',' ',' ',' '], | |
[' ',' ','X',' ',' '], | |
] | |
var m = [ | |
[' ',' ','X'], |
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
ORG='whosonfirst-data'; | |
rm -f "${ORG}.txt" | |
for i in {0..15}; do | |
curl -s "https://api.github.com/orgs/${ORG}/repos?page=${i}&per_page=100" \ | |
| jq -r '.[] | .name' \ | |
>> "${ORG}.txt" | |
done |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
5300100|Aberdeen city | |
4801000|Abilene city | |
4000200|Ada city | |
1301052|Albany city | |
4101000|Albany city | |
3700680|Albemarle city | |
0100988|Albertville city | |
3502000|Albuquerque city | |
0101132|Alexander City city | |
2200975|Alexandria city |