Skip to content

Instantly share code, notes, and snippets.

@happyrobots
happyrobots / benchmark.rb
Created June 5, 2011 20:34
RSpec basic benchmark matchers
require "benchmark"
require "rspec"
module RSpec
module Benchmark
class Result
attr_accessor :slowest, :fastest, :average, :elapsed
def initialize(elapsed)
@elapsed = elapsed

Locate the section for your github remote in the .git/config file. It looks like this:

[remote "origin"]
	fetch = +refs/heads/*:refs/remotes/origin/*
	url = [email protected]:joyent/node.git

Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:

@interface UILabel (Fit)
- (void)fitFontSize
@end
@import ObjectiveC;
@interface NSObject (LN_FORCE_SHAPES)
@end
@implementation NSObject (LN_FORCE_SHAPES)
+ (void)load
{

OS X Screencast to animated GIF

This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.

Screencapture GIF

Instructions

To capture the video (filesize: 19MB), using the free "QuickTime Player" application: