Skip to content

Instantly share code, notes, and snippets.

View nsforge's full-sized avatar
🌿

Nick Forge nsforge

🌿
View GitHub Profile
@nsforge
nsforge / gist:4342663
Created December 20, 2012 03:15
A simple example of how Objective-C's instancetype would be useful in method arguments
@interface MyRequest : NSObject
// Variation One
- (void)startRequestWithCompletionBlock1:(void (^)(MyRequest *request))completionBlock;
// Variation Two
- (void)startRequestWithCompletionBlock2:(void (^)(id request))completionBlock;
@nsforge
nsforge / git_commit_all.sh
Created September 26, 2011 07:01
Script to commit all current changes to the current git repo as well as all git submodules
#!/bin/bash
git submodule foreach "git add ."
git submodule foreach "git commit -m \"$1\""
git add .
git commit -m "$1"