Skip to content

Instantly share code, notes, and snippets.

View seanmcnamara's full-sized avatar

Sean McNamara seanmcnamara

View GitHub Profile
@seanmcnamara
seanmcnamara / Iphone Icon.png Bash Script
Created June 17, 2012 01:15 — forked from jessedc/iOS Icon.png bash script
A simple bash script using OSX command line tool sips to resample a 512x512px image
#!/bin/bash
f=$(pwd)
sips --resampleWidth 512 "${f}/${1}" --out "${f}/iTunesArtwork"
sips --resampleWidth 57 "${f}/${1}" --out "${f}/Icon.png"
sips --resampleWidth 114 "${f}/${1}" --out "${f}/[email protected]"
sips --resampleWidth 29 "${f}/${1}" --out "${f}/Icon-Small.png"
sips --resampleWidth 58 "${f}/${1}" --out "${f}/[email protected]"
sips --resampleWidth 50 "${f}/${1}" --out "${f}/Icon-Small-50.png"
sips --resampleWidth 72 "${f}/${1}" --out "${f}/Icon-72.png"
@seanmcnamara
seanmcnamara / init-throws
Created July 4, 2012 17:29
Initialize with dependencies in objective-c.
@implementation CaseController
@synthesize repoPath;
@synthesize caseInfo;
@synthesize managedObjectContext;
@synthesize pathController;
@synthesize categories;
@synthesize caseStore = _caseStore;
@implementation LFController
@seanmcnamara
seanmcnamara / init-throws
Created July 4, 2012 17:30
Initialize with dependencies in objective-c.
@implementation LFController
- (id)init
{
[self release];
@throw [NSException exceptionWithName:NSInternalInconsistencyException