Skip to content

Instantly share code, notes, and snippets.

View fousa's full-sized avatar

Jelle Vandebeeck fousa

View GitHub Profile
@fousa
fousa / gist:3092431
Created July 11, 2012 19:05
Fake Carrier
//
// Copyright (c) 2012 Cédric Luthi / @0xced. All rights reserved.
//
#if TARGET_IPHONE_SIMULATOR
static NSString * const FakeCarrier = @"AT&T";
#import <objc/runtime.h>
@fousa
fousa / gist:3092441
Created July 11, 2012 19:06
Generate .strings
find -E . -iregex '.*\.(m|h|mm)$' -print0 | xargs -0 genstrings -a -o en.lproj
@fousa
fousa / gist:3092450
Created July 11, 2012 19:07
Core Data Debug
-com.apple.CoreData.SQLDebug 1
@fousa
fousa / gist:3092454
Created July 11, 2012 19:08
Suppress Depreciation
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
// depreciated code
#pragma GCC diagnostic warning "-Wdeprecated-declarations"
@fousa
fousa / gist:3093192
Created July 11, 2012 20:36
Dump MySQL
mysqldump -u USER -p -h HOST DATABASE > FILE
@fousa
fousa / gist:3093203
Created July 11, 2012 20:37
ARC Try:
#import <objc/message.h>
objc_msgSend(_controller, NSSelectorFromString(@"someMethod"));
@fousa
fousa / gist:3093206
Created July 11, 2012 20:37
Dump PSQL
psql db_development < dump.sql
@fousa
fousa / gist:3093210
Created July 11, 2012 20:38
Drop PSQL
dropdb db_development
@fousa
fousa / gist:3093212
Created July 11, 2012 20:38
Disable ARC
-fno-objc-arc
@fousa
fousa / gist:3093216
Created July 11, 2012 20:38
Create Su PSQL
createuser novatio -s