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
pkgutil --expand /path/to/package.pkg /output/destination/ | |
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/perl | |
# hex2uicolor | |
# Copyright 2009 by Carlos McEvilly - Apache License | |
use strict; | |
use warnings; | |
my ($r,$g,$b) = @ARGV; |
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 | |
# create an <img src=""> tag with data for a given .png image file | |
export in=$1 | |
if [[ "$in" == '' ]]; then | |
echo "usage: $0 infile" | |
exit -1 | |
fi |
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 | |
# project rename helper for Xcode 3.x projects. Not yet updated for Xcode 4.x (in particular, workspaces) | |
# makes some assumptions about file locations which may differ from your project layout. | |
# important: also assumes it's OK to rename *every* instance of <oldname> to <newname> in | |
# your project, even in places where they might not be acting as names. | |
echo "this is outdated, so this is provided for reference only. use at your own risk" | |
exit # refuse to run. anyone who runs this should read and understand the whole thing before removing this line. |
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 | |
# doc-methods | |
# no arguments | |
# | |
# usage: load the docs for an obj-c protocol, select all, copy, then run this. | |
# | |
# on osx, takes the contents of the paste buffer and replaces it with | |
# only the lines from the paste buffer that look like obj-c methods, | |
# based on a really simple heuristic |
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 | |
export appname=$1 | |
export simversion="4.3.2" | |
export approot=~/Library/Application\ Support/iPhone\ Simulator/$simversion/Applications | |
if [[ "$appname" == '' ]]; then | |
echo usage: $0 AppName | |
exit -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
git submodule foreach git submodule init && git submodule update --recursive |
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 | |
# <basename><orientation_modifier><scale_modifier><device_modifier>.png | |
export bgcolor=blue | |
export txtcolor=#FFFFFF | |
export fontsm=24 | |
export fontlg=48 | |
# PortraitUpsideDown |
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
xcodebuild -project Foo.xcodeproj -target Foo -configuration Debug -sdk iphonesimulator5.0 clean build | |
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
CGDataRef imageDataRef = CGDataProviderCopyData(CGImageGetDataProvider(myCGImageRef))); | |
OlderNewer