Last active
May 1, 2016 13:03
-
-
Save samnung/8f53983c34782a57f8d1473efe5e6f61 to your computer and use it in GitHub Desktop.
Shortcut to run CocoaPods v1.0 from CococaPods.app when installed older v0.39 in system
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
function pod1 { | |
# Find the CocoaPods runner if the cache variable is not set | |
if [[ -z "$__POD1_LOCATION" || ! -x "$__POD1_LOCATION" ]]; then | |
local location=`mdfind "kMDItemCFBundleIdentifier = 'org.cocoapods.CocoaPods'"` | |
export __POD1_LOCATION="${location}/Contents/Helpers/pod" | |
fi | |
if [[ -z "$__POD1_LOCATION" || ! -x "$__POD1_LOCATION" ]]; then | |
echo "Can't find CocoaPods.app" >&2 | |
return 1 | |
fi | |
${__POD1_LOCATION} $@ | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment