Skip to content

Instantly share code, notes, and snippets.

View edtjones's full-sized avatar

Ed Jones edtjones

  • Canva
  • UK
View GitHub Profile

I had a large dataset in postgis and wanted to avoid the hassle of first exporting it to a several GB geojson file before tiling it with Tippecanoe.

ogr2ogr -f GeoJSON /dev/stdout \                                                                            
PG:"host=localhost dbname=postgres user=postgres password=thepassword" \
-sql "select * from a, roi where a.geom && roi.geom" \
| docker run -i -v ${PWD}:/data tippecanoe:latest tippecanoe \
--output=/data/yourtiles.mbtiles
<!-- <h1 class="article-header">The Making Room</h1> -->
<p>A small paragraph to show <em>emphasis</em> and <strong>important</strong> bits.</p>
<p>Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Vestibulum tortor quam, feugiat vitae, ultricies eget, tempor sit amet, ante. Donec eu libero sit <a href="#">amet quam egestas semper</a>. Aenean ultricies mi vitae est. Mauris placerat eleifend leo.</p>
<p>Curabitur at risus sed tellus tristique bibendum nec sed urna. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Praesent malesuada aliquet quam quis efficitur. Curabitur et quam sollicitudin neque varius laoreet. Aenean non condimentum libero, convallis aliquam est. Suspendisse rhoncus consectetur posuere. Sed dapibus luctus sapien eget varius. Nulla sed felis id risus iaculis mollis. Mauris pulvinar nisl vitae leo euismod, sit amet viverra massa vehicula.</p>
<h2>How to choose the right cake</h2>
@edtjones
edtjones / edgerouter-qos
Last active December 4, 2016 20:10 — forked from beardicus/edgerouter-qos
EdgeRouter Lite QOS Settings
#
# fair-queue based settings for EdgeRouter Lite traffic shaping
#
delete traffic-policy
# download is 8.5Mbps. everything can burst to 100%
# of bandwidth, priority rules keep the garbage in check
$.rails.allowAction = function(link) {
if (!link.attr('data-confirm')) {
return true;
}
$.rails.showConfirmDialog(link);
return false;
};
$.rails.confirmed = function(link) {
link.removeAttr('data-confirm');
@edtjones
edtjones / unicorn
Created September 10, 2013 11:53 — forked from shapeshed/unicorn
#!/bin/sh
set -e
# Example init script, this can be used with nginx, too,
# since nginx and unicorn accept the same signals
# Feel free to change any of the following variables for your app:
TIMEOUT=${TIMEOUT-60}
APP_ROOT=/path/to/your/app/current
PID=$APP_ROOT/tmp/pids/unicorn.pid
ENVIRONMENT=production