Instantly share code, notes, and snippets.


Native OS X OpenStreetMap editing app


Prompted by:

Who wants to write a Mac-native OSM editor with me?

— Ian Dees (@iandees) February 9, 2014
<script async src="//" charset="utf-8"></script>

And a few more key followups:


Keybase proof

I hereby claim:

  • I am incanus on github.
  • I am incanus ( on keybase.
  • I have a public key whose fingerprint is 2231 DFF0 869E E3A5 885A E7D4 F787 7A2B C9C4 0C31

To claim this, I am signing this object:

  • For one regular mug / two shots, use one cup of water (bottom line) and two scoops of beans.
  • For my Peregrine mug / three shots, use 1.5 cups of water (between the two lines) and three scoops of beans.
  • For a Klean Kanteen / four shots, use two cups of water (top line) and four scoops of beans.

Make sure all the equipment is dry, or else keep the grounds in the grinder lid until right before brewing.

Setup a mug or glass with the press and filter. Put the funnel in the top.

Microwave the water on full power.


Two useful shortcuts for managing known wifi networks on OS X.

If you've got a modern Mac with no Ethernet, your wifi interface is en0. Otherwise, it is en1, so replace that below.

alias wifils='networksetup -listpreferredwirelessnetworks en0'

This lets you list (and possibly grep) all known, previously connected wireless networks. Just type wifils.

INFO=$( echo $PWD )/MyApp-Info
TAG=$( git describe --tags `git rev-list --tags --max-count=1` )
if [ -z $( which git ) ]; then
echo "Unable to find git binary in \$GITPATH"
View gist:808151
grep github ./.git/config | sed -e 's/^.*\(*\)\.git$/\1/' -e 's/.*github\.com:*\/*/https:\/\/\//' | xargs open
View gist:926686
// check that popover won't try to move off-screen; dismiss if so
CGFloat pX = newAttachPoint.x;
CGFloat pY = newAttachPoint.y;
CGFloat pWidth = balloon.popoverContentSize.width;
CGFloat pHeight = balloon.popoverContentSize.height;
CGFloat mWidth = map.bounds.size.width;
CGFloat mHeight = map.bounds.size.height;
UIPopoverArrowDirection d = balloon.popoverArrowDirection;
View gist:1045095
- (void)moveBy:(CGSize)delta
// Adjust delta as necessary to constrain latitude, but not longitude.
// This is largely borrowed from -[RMMapView setConstraintsSW:NE:] and -[RMMapView moveBy:]
RMProjectedRect sourceBounds = [self.mercatorToScreenProjection projectedBounds];
RMProjectedSize XYDelta = [self.mercatorToScreenProjection projectScreenSizeToXY:delta];
CGSize sizeRatio = CGSizeMake(((delta.width == 0) ? 0 : XYDelta.width / delta.width),
View gist:1108777
LoadModule dav_svn_module /opt/subversion/lib/svn-apache/
LoadModule authz_svn_module /opt/subversion/lib/svn-apache/
<Location "/svn">
DAV svn
SVNParentPath /usr/local/svnroot
AuthType Basic
AuthName "Subversion Repository"
AuthUserFile /etc/apache2/other/htpasswd
Require valid-user
View gist:1137725
NSArray *colorNames = [NSArray arrayWithObjects:@"red", @"blue", @"yellow", @"green", @"brown", @"purple", @"cyan", @"orange", @"magenta", nil];
NSMutableArray *madeColors = [NSMutableArray array];
for (int c = 0; c < [colorNames count]; c++)
[madeColors addObject:[[UIColor class] performSelector:NSSelectorFromString([NSString stringWithFormat:@"%@Color", [colorNames objectAtIndex:c]])]];