Skip to content

Instantly share code, notes, and snippets.

View alexgleith's full-sized avatar

Alex Leith alexgleith

View GitHub Profile
@alexgleith
alexgleith / Contributors.ipynb
Created July 10, 2018 03:21
Contributors ODC
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.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE WMT_MS_Capabilities SYSTEM "http://schemas.opengis.net/wms/1.1.1/capabilities_1_1_1.dtd" >
<WMT_MS_Capabilities version="1.1.1">
<Service>
<Name>OGC:WMS</Name>
<Title>Web Map Service - GeoWebCache</Title>
<OnlineResource xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:href="http://api.maps.vic.gov.au/vicmapapi/map/wms?SERVICE=WMS&amp;"/>
</Service>
<Capability>
<Request>
@alexgleith
alexgleith / start-ubuntu-16.04-docker.sh
Last active February 4, 2018 01:55
A gist that can be used to bootstrap a Ubuntu EC2 instance with Docker
#!/bin/bash
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | apt-key add -
add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
apt-get update
apt-get install -y docker-ce
usermod -aG docker ubuntu
apt-get install -y python3-pip
pip3 install docker-compose
@alexgleith
alexgleith / turf-line-split-test.geojson
Last active October 2, 2017 21:59
splitLine changing order of split features changes location of split
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
BASE:
var path = require('path')
var config = require('../config')
var cssLoaders = require('./css-loaders')
var projectRoot = path.resolve(__dirname, '../')
var webpack = require('webpack')
module.exports = {
entry: {
@alexgleith
alexgleith / awscli-currentAmzLinux.sh
Created April 1, 2017 00:17 — forked from rdp-cloud/awscli-currentAmzLinux.sh
When run from an EC2 instance this snippet will return the CURRENT ami id for Amazon Linux in the REGION that the instance is running in and load it up into a variable called currentAMI.
#!/bin/bash -xe
# grab the Availability Zone from the Meta Data service
az=$(curl http://169.254.169.254/latest/meta-data/placement/availability-zone/)
# drop the trailing zone to get the REGION the instance is running in.
currentRegion=${az%?}
# retirve the source AMI (latest Amazon Linux image in this case)
currentAMI=$(aws ec2 describe-images --owners self amazon --filters "Name=name,Values=amzn-ami-hvm-*gp2" --query 'Images[].[CreationDate,ImageId]' --output text --region $currentRegion | sort -k1 | tail -n1 | awk '{print $2}')
@alexgleith
alexgleith / collapsing-table.js
Created April 4, 2016 21:44
Collapsing (grouped) tables extension to bootstrap-table.
/**
* @author: Yura Knoxville
* @version: v1.0.0
*/
!function ($) {
'use strict';
var initBodyCaller,

Keybase proof

I hereby claim:

  • I am alexgleith on github.
  • I am alexgleith (https://keybase.io/alexgleith) on keybase.
  • I have a public key whose fingerprint is A534 6E24 5A55 A3C6 1AE4 4C2D 9322 7071 6AD3 C746

To claim this, I am signing this object:

@alexgleith
alexgleith / Zoning.sld
Created April 17, 2015 03:12
Zoning SLD - Tasmanian Planning Scheme Style for GeoServer
<?xml version="1.0" encoding="UTF-8"?><sld:StyledLayerDescriptor xmlns="http://www.opengis.net/sld" xmlns:sld="http://www.opengis.net/sld" xmlns:ogc="http://www.opengis.net/ogc" xmlns:gml="http://www.opengis.net/gml" version="1.0.0">
<sld:NamedLayer>
<sld:Name>Zoning_GCC</sld:Name>
<sld:UserStyle>
<sld:Name>Zoning_GCC</sld:Name>
<sld:FeatureTypeStyle>
<sld:Name>name</sld:Name>
<sld:Rule>
<sld:Name>10 General Residential</sld:Name>
<ogc:Filter>