Skip to content

Instantly share code, notes, and snippets.

@ddribin
ddribin / gist:903804
Created April 5, 2011 15:12
git-svn caveat
For the sake of simplicity and interoperating with a less-capable
system (SVN), it is recommended that all git svn users clone, fetch
and dcommit directly from the SVN server, and avoid all git
clone/pull/merge/push operations between git repositories and
branches. The recommended method of exchanging code between git
branches and users is git format-patch and git am, or just
'dcommit’ing to the SVN repository.
#!/bin/sh
# OBJC_HELP=1 causes the Objective-C runtime to spit out help to stderr
# Pulling in osx/cocoa causes the runtime to be loaded via RubyCocoa
# Redirect sterr to stdout so we can pipe the results through pager
OBJC_HELP=1 /usr/bin/ruby -rosx/cocoa -e '' 2>&1
% crontab -l
# DO NOT EDIT THIS FILE - edit the master and reinstall.
# (/tmp/crontab.4324 installed on Mon Jan 5 10:38:03 2004)
# (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)
PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/bin
01 * * * * run-parts ${HOME}/etc/cron.hourly
02 05 * * * run-parts ${HOME}/etc/cron.daily
22 05 * * 1 run-parts ${HOME}/etc/cron.weekly
42 05 1 * * run-parts ${HOME}/etc/cron.monthly
NSCalendar * calendar =
[[NSCalendar alloc] initWithCalendarIdentifier:NSGregorianCalendar];
[calendar autorelease];
pre
{
word-wrap: break-word !important;
}
ZeroingWeakRef(54051) malloc: recording malloc stacks to disk using standard recorder
ZeroingWeakRef(54051) malloc: stack logging compaction turned off; size of log files on disk can increase rapidly
ZeroingWeakRef(54051) malloc: stack logs deleted from /tmp/stack-logs.54051.arch.y6uZul.index
ZeroingWeakRef(54051) malloc: stack logs being written into /tmp/stack-logs.54051.ZeroingWeakRef.YizJXG.index
2010-07-09 19:30:24.199 ZeroingWeakRef[54051:a0b] obj is <NSObject: 0x10010c560>
2010-07-09 19:30:24.206 ZeroingWeakRef[54051:a0b] Creating weak ref
2010-07-09 19:30:24.208 ZeroingWeakRef[54051:a0b] obj: <NSObject_MAZeroingWeakRefSubclass: 0x10010c560> ref: <MAZeroingWeakRef_MAZeroingWeakRefSubclass: 0x1001102a0 -> <NSObject_MAZeroingWeakRefSubclass: 0x10010c560>> ref2: <MAZeroingWeakRef: 0x100111c90 -> <MAZeroingWeakRef_MAZeroingWeakRefSubclass: 0x1001102a0 -> <NSObject_MAZeroingWeakRefSubclass: 0x10010c560>>>
2010-07-09 19:30:24.209 ZeroingWeakRef[54051:a0b] Releasing obj
2010-07-09 19:30:24.210 ZeroingWeakRe
--------------------- pam_unix Begin ------------------------
sshd:
Authentication Failures:
root (200.75.50.13): 8 Time(s)
root (24.114.227.114): 5 Time(s)
root (210.51.180.212): 3 Time(s)
---------------------- pam_unix End -------------------------
#import "UrlDownloaderOperation.h"
@interface UrlDownloaderOperation ()
- (void)finish;
@end
@implementation UrlDownloaderOperation
@ddribin
ddribin / gist:380357
Created April 27, 2010 05:28
single return + helper
- (void)setError:(NSError **)error withOSStatus:(OSStatus)status
{
if (error != NULL) {
*error = [NSError errorWithDomain:NSOSStatusErrorDomain code:status userInfo:nil];
}
}
- (BOOL)play:(NSError **)error;
{
NSAssert(_graph == NULL, @"Graph is already started");
@ddribin
ddribin / gist:380353
Created April 27, 2010 05:21
early return + helper
- (void)setError:(NSError **)error withOSStatus:(OSStatus)status
{
if (error != NULL) {
*error = [NSError errorWithDomain:NSOSStatusErrorDomain code:status userInfo:nil];
}
}
- (BOOL)play:(NSError **)error;
{
NSAssert(_graph == NULL, @"Graph is already started");