Skip to content

Instantly share code, notes, and snippets.

View eightbitraptor's full-sized avatar

Matt Valentine-House eightbitraptor

View GitHub Profile
@eightbitraptor
eightbitraptor / main.rs
Created June 19, 2014 21:54
I don't understand how linking works I think
#![link_args = "-lkyotocabinet"]
extern crate libc;
use libc::types;
extern {
fn kctime() -> libc::c_double;
}
#[test]
;; This is a bugfix to tell Magit to stop using the default system emacs client and instead use the Homebrew one
;; This stops a completely new frame opening up when we try and commit
(set-variable 'magit-emacsclient-executable "/usr/local/opt/emacs/bin/emacsclient")
@eightbitraptor
eightbitraptor / build.gradle
Created April 24, 2014 20:52
Build.gradle for Rubolectric integration
buildscript {
repositories {
mavenCentral()
maven { url 'https://oss.sonatype.org/content/repositories/snapshots' }
}
dependencies {
classpath 'com.android.tools.build:gradle:0.9.+'
classpath 'com.novoda.gradle:robolectric-plugin:0.0.1-SNAPSHOT'
}
}

Keybase proof

I hereby claim:

  • I am eightbitraptor on github.
  • I am eightbitraptor (https://keybase.io/eightbitraptor) on keybase.
  • I have a public key whose fingerprint is 9A48 263E E8D0 8995 9732 3C63 4EA7 1D48 A84F 23DD

To claim this, I am signing this object:

# Autocomplete the list of authors configured in your Git Pair authors list
PAIRS=( $(git pair authors 2>&1 | awk '{print $NF}' | sed -e 's/authors//' | xargs echo -n) )
unset PAIRS[0]
complete -o default -W "${PAIRS[*]}" git pair
;; Remove Scroll bar and toolbar, leave the menu though, it can be useful
(toggle-scroll-bar -1)
(menu-bar-mode 1)
(tool-bar-mode 0)
;; Start in the Scratch buffer by default
(blink-cursor-mode 0)
(setq initial-scratch-message "")
(setq inhibit-startup-message t)
@eightbitraptor
eightbitraptor / .offlineimaprc
Created January 8, 2014 09:17
offlineimaprc
[general]
ui = ttyui
accounts = Eightbitraptor
pythonfile=~/.mutt/offlineimap.py
fsync = False
cacertfile = ~/.mutt/certificates
[Account Eightbitraptor]
localrepository = Eightbitraptor-Local
remoterepository = Eightbitraptor-Remote
@eightbitraptor
eightbitraptor / patch.sh
Created December 10, 2013 13:54
apply a patch to a single file from a specific branch or revision from git.
# From the root of your repository.
git show <treeish> -- /path/to/file.rb | patch -p1
#!/usr/bin/python
import re, subprocess
def get_keychain_pass(account=None, server=None):
params = {
'security': '/usr/bin/security',
'command': 'find-internet-password',
'account': account,
'server': server,
'keychain': '/Users/matthewvalentine-house/Library/Keychains/login.keychain',
"use strict";
var MyClass = (function() {
function MyClass(publicString) {
this.publicString = publicString;
};
var privateString = "I'm a private string that can't be accessed directly";
// ============================================================================