This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"Version": "2012-10-17", | |
"Statement": [ | |
{ | |
"Sid": "AddPerm", | |
"Effect": "Allow", | |
"Principal": { | |
"AWS": "*" | |
}, | |
"Action": "s3:GetObject", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| |-bosh-agent,675 -I aws -P ubuntu -C /var/vcap/bosh/agent.json | |
| | |-bash,1583 -x packaging | |
| | | `-gem,12126 /var/vcap/packages/ruby/bin/gem install --local --verbose --no-ri --no-rdoc -w -n/var/vcap/package | |
| | | `-{gem},12127 | |
[#<Thread:0x007fd5f0382660 sleep>] | |
eval:1:in `backtrace' | |
eval:1:in `block in connect' | |
/var/vcap/packages/ruby/lib/ruby/2.1.0/net/http.rb:879:in `initialize' | |
/var/vcap/packages/ruby/lib/ruby/2.1.0/net/http.rb:879:in `open' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$require_indent = 0 | |
$require_times = [] | |
$require_abs_start = Time.now.to_f | |
def putz(*args, &blk) | |
puts(*args, &blk) | |
end | |
module Kernel | |
alias_method :old_require, :require |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
MockClass.define(:MockGateway, Gateway) do | |
overrides :create do |name, type, otps={}| | |
# noop | |
end | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
setenv("NSObjCMessageLoggingEnabled", "YES", 1); | |
instrumentObjcMessageSends(YES); | |
instrumentObjcMessageSends(NO); | |
grep -v '\- DVT' __FILE__ | grep -v '\- NS' | grep -v '\+ NS' | grep -v '\+ DVT' | grep -v '_NS' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (void)_listMenuItems { | |
NSMenu *mainMenu = [[NSApplication sharedApplication] mainMenu]; | |
for (NSMenuItem *item in [mainMenu itemArray]) { | |
NSLog(@"Menu %@:", [item title]); | |
for (NSMenuItem *subitem in [item.submenu itemArray]) { | |
NSLog(@"\t%@\n\t\t%@ - %@ - %@\n", | |
[subitem title], | |
NSStringFromSelector([subitem action]), | |
subitem.target, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void MyCallBack (CFNotificationCenterRef center, | |
void *observer, | |
CFStringRef name, | |
const void *object, | |
CFDictionaryRef userInfo) | |
{ | |
NSLog(@"---\n name: %@\n info: %@", name, userInfo); | |
} | |
CFNotificationCenterAddObserver(CFNotificationCenterGetLocalCenter(), NULL, MyCallBack, NULL, NULL, CFNotificationSuspensionBehaviorDeliverImmediately); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#import <Foundation/Foundation.h> | |
typedef void(^VoidBlock)(void); | |
@interface FakeRunLoop : NSObject | |
+ (void)run:(VoidBlock)block; | |
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[schwa@ungoliant] ~$ export OBJC_HELP=1 | |
[schwa@ungoliant] ~$ /Applications/Safari.app/Contents/MacOS/Safari | |
objc[10559]: Objective-C runtime debugging. Set variable=YES to enable. | |
objc[10559]: OBJC_HELP: describe available environment variables | |
objc[10559]: OBJC_PRINT_OPTIONS: list which options are set | |
objc[10559]: OBJC_PRINT_IMAGES: log image and library names as they are loaded | |
objc[10559]: OBJC_PRINT_LOAD_METHODS: log calls to class and category +load methods | |
objc[10559]: OBJC_PRINT_INITIALIZE_METHODS: log calls to class +initialize methods | |
objc[10559]: OBJC_PRINT_RESOLVED_METHODS: log methods created by +resolveClassMethod: and +resolveInstanceMethod: | |
objc[10559]: OBJC_PRINT_CLASS_SETUP: log progress of class and category setup |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Run application tests from the command line: | |
// xcodebuild -project project.xcodeproj -target projectTests -configuration Release -sdk iphonesimulator4.3 -arch i386 TEST_HOST= BUNDLE_LOADER= TEST_AFTER_BUILD=YES build | |
// (How to set up: http://pivotallabs.com/users/dmitriy/blog/articles/1879-run-ocunit-application-tests-from-the-command-line) | |
#import <SenTestingKit/SenTestingKit.h> | |
#import <objc/runtime.h> | |
@implementation NSBundle (MainBundleHijack) | |
static NSBundle *mainBundle__ = nil; |