This file contains hidden or 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
| # xcode-build-bump.sh | |
| # @desc Auto-increment the build number every time the project is run. | |
| # @usage | |
| # 1. Select: your Target in Xcode | |
| # 2. Select: Build Phases Tab | |
| # 3. Select: Add Build Phase -> Add Run Script | |
| # 4. Paste code below in to new "Run Script" section | |
| # 5. Drag the "Run Script" below "Link Binaries With Libraries" | |
| # 6. Insure that your starting build number is set to a whole integer and not a float (e.g. 1, not 1.0) |
This file contains hidden or 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
| - (UIImage *)radialGradientImage:(CGSize)size start:(float)start end:(float)end centre:(CGPoint)centre radius:(float)radius { | |
| // Render a radial background | |
| // http://developer.apple.com/library/ios/#documentation/GraphicsImaging/Conceptual/drawingwithquartz2d/dq_shadings/dq_shadings.html | |
| // Initialise | |
| UIGraphicsBeginImageContextWithOptions(size, YES, 1); | |
| // Create the gradient's colours | |
| size_t num_locations = 2; | |
| CGFloat locations[2] = { 0.0, 1.0 }; |
This file contains hidden or 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
| - (UIImage *)radialGradientImage:(CGSize)size start:(UIColor*)start end:(UIColor*)end centre:(CGPoint)centre radius:(float)radius { | |
| // Render a radial background | |
| // http://developer.apple.com/library/ios/#documentation/GraphicsImaging/Conceptual/drawingwithquartz2d/dq_shadings/dq_shadings.html | |
| // Initialise | |
| UIGraphicsBeginImageContextWithOptions(size, 0, 1); | |
| // Create the gradient's colours | |
| size_t num_locations = 2; | |
| CGFloat locations[2] = { 0.0, 1.0 }; |
This file contains hidden or 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 python | |
| # | |
| # savethemblobs.py | |
| # A simple script to grab all SHSH blobs from Apple that it's currently signing to save them locally and on Cydia server. | |
| # And now also grabs blobs already cached on Cydia and iFaith servers to save them locally. | |
| # | |
| # Copyright (c) 2013 Neal <neal@ineal.me> | |
| # | |
| # examples: | |
| # savethemblobs.py 1050808663311 iPhone3,1 |
This file contains hidden or 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
| - (uint64_t)freeDiskspace | |
| { | |
| uint64_t totalFreeSpace = 0; | |
| __autoreleasing NSError *error = nil; | |
| NSString *path = [self applicationDocumentsDirectory]; | |
| NSDictionary *dictionary = [[NSFileManager defaultManager] attributesOfFileSystemForPath:path error: &error]; | |
| if (dictionary) { | |
| NSNumber *freeFileSystemSizeInBytes = [dictionary objectForKey:NSFileSystemFreeSize]; |