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
#!/bin/bash | |
SEARCH='print\(.*' | |
echo "Searching ${SRCROOT} for ${SEARCH}" | |
find "${SRCROOT}" \( -name "*.swift" \) -not -path "${SRCROOT}/Pods/*" -print0 | xargs -0 egrep --with-filename --line-number --only-matching "($SEARCH).*\$" | perl -p -e "s/($SEARCH)/ warning: Print Violation (use logger instead): \$1/" |
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 *)colorForImage:(UIImage *)image atPoint:(CGPoint)point | |
{ | |
CGDataProviderRef provider = CGImageGetDataProvider(image.CGImage); | |
CFDataRef pixelData = CGDataProviderCopyData(provider); | |
const UInt8* data = CFDataGetBytePtr(pixelData); | |
int numberOfColorComponents = 4; // R,G,B, and A | |
float positionX = point.x; | |
float positionY = point.y; | |
float imageWidth = image.size.width; |
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> | |
@interface UntouchableUIViewContainer : UIView | |
@end |