Skip to content

Instantly share code, notes, and snippets.

View ajmcmiddlin's full-sized avatar

Andrew ajmcmiddlin

  • Brisbane, Australia
View GitHub Profile
@ajmcmiddlin
ajmcmiddlin / gis-notes.md
Last active February 14, 2017 01:08
Notes from GIS/web mapping research
@ajmcmiddlin
ajmcmiddlin / (Spac)emacs cheat sheet.md
Last active July 18, 2017 00:36
Stuff ajmccluskey needs to remember about (Spac)emacs

General

  • Space *: Search for word under cursor
  • Space t F toggles auto-fill-mode, which enables hard wrapping
  • C-x f calls set-fill-column - sets the column to wrap at
  • g q to format (applies wrapping if auto-fill-mode enabled)
  • Space s c clears search term
  • * e edit word under cursor and change all in file/display (depending on mode)
  • Space f y echo and yank filename for current buffer
#include <string>
#include <mapnik/map.hpp>
#include <mapnik/datasource_cache.hpp>
#include "vector_tile_processor.hpp"
#include "mvt_from_geojson.h"
struct _mvtc_return {
mvtc_return_code return_code;
std::string message;
@ajmcmiddlin
ajmcmiddlin / dump-access-to-csv
Created July 16, 2015 23:43
Dump Access database to CSVs with mdbtools
#!/usr/bin/env bash
db="$1"
out_dir="$2"
tables="$(mdb-tables -1 "$db")"
echo "$tables" | while read t; do
mdb-export "$db" "$t" > "${out_dir}/${t}.csv"
done
@ajmcmiddlin
ajmcmiddlin / exercises.clj
Created March 24, 2013 09:41
Exercise solutions from the March 2013 Melbourne Clojure Workshop. Exercises taken from the first 5 Project Euler problems.
(ns clj-workshop.exercises)
(defn multiple-of
[n]
#(= 0 (mod % n)))
(defn ex1
[]
(let [multiple-of-3? (multiple-of 3)
multiple-of-5? (multiple-of 5)]