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
#!/usr/bin/env ruby | |
# gist: https://gist.github.com/3217498 | |
# This script can be called from an Xcode 'Run Script' build phase at the | |
# beginning of the build process, like this: | |
# | |
# ${PROJECT_DIR}/LocalizeStringsFromAndroid.rb ${PROJECT_NAME} | |
# | |
# This script should be placed in the same directory as your .xcodeproj |
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
/* This SnapshotHelper class should be compatible with SnapshotHelper.swift version 1.2 */ | |
@import Foundation; | |
@import XCTest; | |
@interface SnapshotHelper : NSObject | |
- (instancetype)initWithApp:(XCUIApplication*)app; | |
- (void)snapshot:(NSString*)name waitForLoadingIndicator:(BOOL)wait; |
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
/* | |
UIColor from hex value in Objective-C | |
*/ | |
#define UIColorFromRGB(rgbHex) [UIColor colorWithRed:((float)((rgbHex & 0xFF0000) >> 16))/255.0 green:((float)((rgbHex & 0xFF00) >> 8))/255.0 blue:((float)(rgbHex & 0xFF))/255.0 alpha:1.0] | |
// Usage: | |
UIColor *bgColor = UIColorFromRGB(0xCCEEFF); |
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
# opening and closing windows and popovers | |
defaults write -g NSAutomaticWindowAnimationsEnabled -bool false | |
# smooth scrolling | |
defaults write -g NSScrollAnimationEnabled -bool false | |
# showing and hiding sheets, resizing preference windows, zooming windows | |
# float 0 doesn't work | |
defaults write -g NSWindowResizeTime -float 0.001 |