Skip to content

Instantly share code, notes, and snippets.

Avatar

Wayne Burkett wayneburkett

View GitHub Profile
View README.md
View README.md

How to create this file

  1. First you'll need to download the latest parcel data (shapefiles and extended parcel records) and generate a SQLite database:
# download the shapefiles and parcel data, merge it all together, and dump it into a database
curl -L "https://www.stlouis-mo.gov/data/upload/data-files/prcl_shape.zip" -o prcl.zip && \
unzip prcl.zip && \
curl -LO "https://www.stlouis-mo.gov/data/upload/data-files/par.zip" && \
unzip par.zip && \
@wayneburkett
wayneburkett / README.md
Last active Jun 27, 2020
Get pixel color from canvas on mouseover
@wayneburkett
wayneburkett / everylotpvd
Last active Nov 8, 2019
Create an everylotbot for Providence, RI
View everylotpvd
# download the shapefile and dump it into a database
mkdir tmp && \
curl -L "https://data.providenceri.gov/api/geospatial/78bu-i8at?method=export&format=Shapefile" -o tmp/prcl.zip && \
cd tmp && \
unzip prcl.zip && \
ogr2ogr -f SQLite prcl_raw.db geo_export_*.shp -t_srs EPSG:4326
# create a table with everything you'd need to run an everylot bot
# http://fakeisthenewreal.org/everylot/
# change the table name to whatever the downloads give you (it's randomized)
View nyctrees
# get a pared-down database of the trees in NYC
# the downloaded CSV is ~210M
# the generated DB is ~22M
mkdir trees && \
curl -L "https://data.cityofnewyork.us/api/views/uvpi-gqnh/rows.csv?accessType=DOWNLOAD" -o trees/trees.csv && \
ogr2ogr -f SQLite trees.db trees/trees.csv -nln trees -dialect sqlite \
-sql "SELECT tree_id AS id, \
ROUND(latitude, 6) lat, \
ROUND(longitude, 6) lon \
FROM trees"
View git.alias.about.sh
alias.about !describe() { msg="$1"; git config branch."$(git rev-parse --abbrev-ref HEAD)".description ${msg:+"$msg"}; }; describe
@wayneburkett
wayneburkett / generate.bash
Last active Mar 27, 2019
St. Louis properties owned by Paul McKee's Northside Regeneration LLC
View generate.bash
# see this gist for instructions to generate the database of parcels this was created from
# https://gist.github.com/wayneburkett/9fc130e1e2f1f6105a6fa2c0e74c2e3c
ogr2ogr -f GeoJSON northside.geojson prcl.shp -t_srs EPSG:4326 -select handle -where "ownername LIKE 'NORTHSIDE REGEN%'"
View 5thward.geojson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View absentee.geojson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View vacants.geojson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.