Public Gists by mkhl

Gravatar
Sat Oct 24 02:45:53 -0700 2009
1
2
3
# -*- mode: ruby -*-
 
process do |files|
gist: 173475 Git bundle "replacement"
Gravatar
Sun Aug 23 14:57:08 -0700 2009
1
2
3
#!/bin/bash
require_cmd gitx
gitx
gist: 172793 Userscript for Chroma-Hash ...
Gravatar
Sat Aug 22 07:07:51 -0700 2009
1
2
3
// ==UserScript==
// @name Chroma-Hash password visualization
// @namespace http://purl.org/net/mkhl
gist: 159706 Cocoa UI Unit Testing
Gravatar
Sat Aug 01 09:18:05 -0700 2009
1
2
3
// Cocoa UI Unit Testing
// Source: http://eschatologist.net/blog/?p=205
 
gist: 159461 Small and generic Makefile ...
Gravatar
Fri Jul 31 14:44:45 -0700 2009
1
2
3
PROJECT=foo
SOURCES=bar.c baz.c
LIBRARY=nope
gist: 158450 Replace triple dots with pr...
Gravatar
Wed Jul 29 16:09:35 -0700 2009
1
2
3
// Replace triple dots with proper ellipses.
// Source: http://www.mikeabdullah.net/ellipses_and_sheepkit.html
 
gist: 141927 Disable OS X security warni...
Gravatar
Mon Jul 06 23:44:33 -0700 2009
1
2
3
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/
PropertyList-1.0.dtd">
Gravatar
Tue Jun 23 07:17:43 -0700 2009
1
2
3
#!/usr/bin/env ruby -wKU -rubygems
 
# http://www.stompy.org/2008/08/14/xcode-and-git-another-build-script/
gist: 130149 git-up
Gravatar
Mon Jun 15 07:59:54 -0700 2009
1
2
3
 #!/bin/bash
git push "${1:-origin}" "$(git symbolic-ref HEAD 2>/dev/null|cut -d/ -f3)"
 
gist: 123525 Patch to `/usr/libexec/path...
Gravatar
Thu Jun 04 01:53:31 -0700 2009
1
2
3
Patch to `/usr/libexec/path_helper` to prevent hangs with long `PATH`s.
--- path_helper_bak 2009-05-07 15:54:37.000000000 +0200
+++ path_helper 2009-06-04 10:51:39.000000000 +0200
gist: 119929 Reads a file containing Esp...
Gravatar
Fri May 29 05:34:37 -0700 2009
1
2
3
#!/usr/bin/env ruby -wKU -rubygems
 
require "nokogiri"
gist: 119514 Markdown Sugar: Accept the ...
Gravatar
Thu May 28 12:14:41 -0700 2009
1
2
3
From bf07bf76efbf0ebea77f34d884a0cda1911bbe08 Mon Sep 17 00:00:00 2001
From: Martin Kuehl <martin.kuehl@gmail.com>
Date: Wed, 27 May 2009 19:22:54 +0200
gist: 119513 Markdown Sugar: fix orderin...
Gravatar
Thu May 28 12:14:26 -0700 2009
1
2
3
From 464f270b9b972b673f59e11d4056988c589e6dc2 Mon Sep 17 00:00:00 2001
From: Martin Kuehl <martin.kuehl@gmail.com>
Date: Wed, 27 May 2009 19:13:40 +0200
gist: 115578 Proper Key-Value Observer U...
Gravatar
Thu May 21 10:24:46 -0700 2009
1
2
3
// Source: http://www.dribin.org/dave/blog/archives/2008/09/24/proper_kvo_usage/
 
// Define a static object; strings are easily readable, which is a plus
gist: 115500 Define a protocol MyProtoco...
Gravatar
Thu May 21 07:58:00 -0700 2009
1
2
3
// Define a protocol MyProtocol that inherits from the NSObject protocol.
// This way, calls to NSObject messages (release, retain, …) don’t warn.
// Source: http://www.mobileorchard.com/idprotocol-retainrelease-and-protocol-inheritance/
Gravatar
Fri Apr 24 18:52:03 -0700 2009
1
2
3
// Getting Loaded
// Source: http://googlemac.blogspot.com/2006/11/getting-loaded.html
 
gist: 89546 Disable yasnippet expansion...
Gravatar
Thu Apr 02 15:51:36 -0700 2009
1
2
3
(eval-after-load "yasnippet-bundle"
  '(defadvice yas/expand (around mkhl-yas/expand-or-indent)
     (let ((in-indentation? (looking-back (rx bol (0+ blank)))))
gist: 59891 Insert the Current URL of t...
Gravatar
Sat Feb 07 06:30:59 -0800 2009
1
2
3
#!/usr/bin/env ruby -rubygems
 
# Unicode considerations:
gist: 40353 File Creation Date via `mdls`
Gravatar
Sat Dec 27 18:11:12 -0800 2008
1
2
3
# Find out a files "creation time"
# Source: http://inessential.com/?comments=1&postid=3576
mdls -name kMDItemContentCreationDate -raw #{f}
Gravatar
Mon Dec 08 10:30:58 -0800 2008
1
2
3
# prevent the use of `` in tests
Spec::Runner.configure do |configuration|
  backtick = nil # establish the variable in this scope