Skip to content

Instantly share code, notes, and snippets.

@mttrb
mttrb / keybase.md
Created February 26, 2015 16:02
keybase.md

Keybase proof

I hereby claim:

  • I am mttrb on github.
  • I am mttrb (https://keybase.io/mttrb) on keybase.
  • I have a public key whose fingerprint is E158 01D0 3569 406F EE3D 2132 D19E 2B6E 3FE6 11DC

To claim this, I am signing this object:

@mttrb
mttrb / compile.sh
Created June 11, 2014 06:14
CodeRunner compile.sh script to support Swift
#!/bin/bash
# This is a CodeRunner compilation script. Compilation scripts are used to
# compile code before being run using the run command specified in CodeRunner
# preferences. This script should have the following properties:
#
# Launch directory ($PWD): Will be the same as the file being run
#
# Exit status: Should be 0 on success (will cause CodeRunner
# to continue and execute the run command)
#
@mttrb
mttrb / BLCURLProtocol.m
Last active January 29, 2017 10:59
NSURLProtocol subclass that allows downloads to be intercepted.
//
// BLCURLProtocol.m
// URLProtocol
//
// Created by Matthew Robinson on 17/09/13.
// Copyright (c) 2013 Blended Cocoa. All rights reserved.
//
#import "BLCURLProtocol.h"
@mttrb
mttrb / ElecraftT1.ino
Last active March 14, 2019 22:00
Elecraft T1 Arduino Interface to integrate with DDUtil and the FlexRadio 1500
/******************************************************
* Elecraft T1 Interface *
* *
* This Arduino sketch allows DDUtil to control *
* an Elecraft T1 ATU via the T1's remote control *
* interface. *
* *
* Copyright (c) Matthew Robinson - VK6MR, 2011 *
* *
* This code is released under a Creative Commons *
@mttrb
mttrb / .bash_profile
Created November 21, 2012 02:47
Bash Prompt - Success/Fail and Git Branch
function parse_git_branch {
git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ \[\1\]/'
}
function prompt {
local DEFAULT="\[\033[0m\]"
local RED="\[\033[0;31m\]"
local GREEN="\[\033[0;32m\]"
local BLUE="\[\033[0;34m\]"
@mttrb
mttrb / NSArray+NegativeIndexes.m
Created November 15, 2012 02:54
Objective-C Literals: Negative Array Subscripts
//
// NSArray+NegativeIndexes.m
// Allow Negative Array Literals
//
// Created by Matthew Robinson on 25th October 2012.
// Copyright (c) 2012 Matthew Robinson. All rights reserved.
//
// WARNING: This is a proof of concept and should not be used
// in production code. This could break at anytime.