Skip to content

Instantly share code, notes, and snippets.

@robhoare
robhoare / map.geojson
Created August 10, 2013 05:25
Canada census 1921, Toronto Centre: Sub-District 48 - Ward 3 Polling Subdivision no. 80. Comprising Charles Street, both sides, from Church to Jarvis Street; Hayden Street, both sides, from Church Street to east end; Bloor Street, south side, from Church toJrvis Street; Church Street, both sides, from Isabella to Bloor Street, Jarvis Street, wes…
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@robhoare
robhoare / oai-pmh
Last active August 29, 2015 14:05
Example OAI-PMH
<record>
<header>
<identifier>00208b0d-f720-a7cf-d411-992006f9c8ba</identifier>
<datestamp>2014-08-29T05:53:29Z</datestamp>
</header>
<metadata>
<a2a:A2A Version="1.7" xmlns:a2a="http://Mindbus.nl/A2A" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://Mindbus.nl/A2A http://Mindbus.nl/A2A/A2AAllInOne_v.1.7.xsd">
<a2a:Person pid="Person1">
<a2a:PersonName>
@robhoare
robhoare / extract.sh
Last active August 29, 2015 14:12
Turn saved data from Scotlandspeople Valuation Rolls into tsv
grep -h '<td>' *.html | sed -e 's/<\/td>*//g' | sed -e 's/&nbsp;*//g'| sed -e 's/<td>*/\t/g' | sed -e 's/^[ \t]*//'
@robhoare
robhoare / james.json
Created January 18, 2015 03:36
Familysearch record example - sort-of Gedcom-X for records
{
"metadata": {
"sources": [
{
"id": "s1",
"identifier": {
"value": "https://familysearch.org/pal:/MM9.3.1/TH-1951-26085-5200-94?cc=1952868"
},
"creator": [
"das.familysearch.org"
@robhoare
robhoare / edward,json
Created January 18, 2015 04:33
Example of Familysearch json for a marriage
{
"metadata": {
"externalId": [
{
"value": "291562957",
"type": "org.familysearch.easy.record_id"
}
],
"format": {
"value": "application/sord+xml"
@robhoare
robhoare / sed
Created January 20, 2015 06:33
Sed Notes
-------------------------------------------------------------------------
USEFUL ONE-LINE SCRIPTS FOR SED (Unix stream editor) Dec. 29, 2005
Compiled by Eric Pement - pemente[at]northpark[dot]edu version 5.5
Latest version of this file (in English) is usually at:
http://sed.sourceforge.net/sed1line.txt
http://www.pement.org/sed/sed1line.txt
This file will also available in other languages:
Chinese - http://sed.sourceforge.net/sed1line_zh-CN.html
@robhoare
robhoare / finfo
Last active August 29, 2015 14:19
Count all files in a directory and it's subdirectories
ls -R -1 $1 | wc -l
@robhoare
robhoare / eu-iso.md
Last active August 29, 2015 14:26
ISO Codes of Countries and Territories in/near the European Union

#ISO Codes of Countries and Territories in/near the European Union For purposes like the EU cookie law, it's useful to know what countries and territories could be considered to be within the EU. I've erred on the side of over-inclusiveness in the following lists, rather than being legally precise.

For each country or territory, I've given the ISO code as you would get from IP locators like Maxmind.

@robhoare
robhoare / logip.md
Last active August 29, 2015 14:26
Apache: Log IP correctly when using a CDN

#Apache: Log IP correctly when using a CDN

(assumes Ubuntu)

##Edit Config

in /etc/apache2/apache2.conf

after HostnameLookups Off add

Verifying that +robhoare is my blockchain ID. https://onename.com/robhoare