Skip to content

Instantly share code, notes, and snippets.

View nestserau's full-sized avatar

Aleks Nestserau nestserau

  • Nederland, Randstad
View GitHub Profile
@nestserau
nestserau / gist:11364086
Last active August 29, 2015 14:00
One-line git log formatting with short hash. Supports terminal colorizing.
$ git config format.pretty "format:%C(auto)%h %s"
@nestserau
nestserau / gist:1292649
Created October 17, 2011 13:53
Invoke Juicer from Ant build script
<macrodef name="juicer">
<attribute name="inputFile" />
<!-- none|soft|rails|hard -->
<attribute name="cacheBuster" default="none" />
<!-- none|data_uri -->
<attribute name="embedImages" default="data_uri" />
<sequential>
<exec executable="juicer" failOnError="true" logError="true">
<arg value="-v" />
<arg value="merge" />
/**
* This will convert DateTime (.NET) object serialized as JSON by WCF to a NSDate object.
*/
+ (NSDate *)dateFromJSONTicks:(NSString *)inputString;
@nestserau
nestserau / gist:296671
Created February 6, 2010 11:52
Picking an email address from Address Book with no fail
- (BOOL)peoplePickerNavigationController:(ABPeoplePickerNavigationController *)
peoplePicker shouldContinueAfterSelectingPerson:(ABRecordRef)person
property:(ABPropertyID)property identifier:(ABMultiValueIdentifier)identifier {
ABMultiValueRef emails = ABRecordCopyValue(person, property);
CFStringRef email = ABMultiValueCopyValueAtIndex(emails, identifier);
NSString *str = [textField text];
if (![str isEqualToString:@""]) {
@nestserau
nestserau / MainController.h
Created February 6, 2010 11:39
Простое введение в компонентно-ориентированное программирование под iPhone
@class SCViewSlider;
@interface MainController : UIViewController {
@private
SCViewSlider *_viewSlider;
}
@property (nonatomic, retain) IBOutlet SCViewSlider *viewSlider;
@end