Skip to content

Instantly share code, notes, and snippets.

View robcowie's full-sized avatar

Rob Cowie robcowie

  • Recycleye
  • Leeds/London, United Kingdom
View GitHub Profile
@robcowie
robcowie / keybase.md
Created October 12, 2014 10:53
keybase.md

Keybase proof

I hereby claim:

  • I am robcowie on github.
  • I am robcowie (https://keybase.io/robcowie) on keybase.
  • I have a public key whose fingerprint is 5A09 8AFB 0AF3 4347 454B 663C 058C 3D2D 3E9A E50C

To claim this, I am signing this object:

@robcowie
robcowie / motd.txt
Created December 9, 2014 13:02
Dimi MOTD
.-. .-.
| \/ |
/, ,_ `'-.
.-|\ /`\ '.
.' 0/ | 0\ \_ `".
.-' _,/ '--'.'|#''---'
`--' | / \#
| / \#
\ ;|\ .\#
|' ' // \ ::\#
@robcowie
robcowie / leaflet1.html
Created January 26, 2015 10:58
Minimal leafletjs map
<!DOCTYPE html>
<html>
<head>
<title></title>
<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet-0.7.3/leaflet.css" />
<script src="https://cdnjs.cloudflare.com/ajax/libs/leaflet/0.7.3/leaflet.js"></script>
<!-- <script src="http://maps.stamen.com/js/tile.stamen.js?v1.3.0"></script> -->
<style>
#map { height: 450px; }
</style>
# Send
openssl aes-256-cbc -salt -a -e -in /path/to/file | nc -l 3333
# Receive
nc {ip} 3333 | openssl aes-256-cbc -salt -a -d -out /path/to/file
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@robcowie
robcowie / geodata.md
Created March 29, 2015 12:40
List of Geographical Data Sets
@robcowie
robcowie / pr_template.md
Created April 1, 2015 14:11
Pull Request Template

What's this PR do?

Where should the reviewer start?

How should this be manually tested?

Any background context you want to provide?

What are the relevant tickets?

Screenshots (if appropriate)

Questions:

@robcowie
robcowie / Prettyprint JSON alias.sh
Created April 8, 2010 12:39
Commandline alias to prettyprint json
alias ppjson='python -c "import simplejson, sys; print simplejson.dumps(simplejson.loads(sys.stdin.read()), indent=4)" | pygmentize -f console -l js'
// Usage
// $.dataSpy()
// $(document).bind('data.change', function(){console.log('data changed')} )
// $(document).bind('data.unchange', function(){console.log('data unchanged')} )
(function($) {
function hash(data, n) {
var norm = Math.pow(2, -32);
@robcowie
robcowie / WildcardDict.py
Created April 28, 2010 18:17
Dict that supports wildcards in sequence keys
# -*- coding: utf-8 -*-
import timeit
class Wildcard(object):
""""""
@classmethod
def any(cls, *args, **kargs):
cmp_func = lambda other: True
return Wildcard(cmp_func, *args, **kargs)