Skip to content

Instantly share code, notes, and snippets.

@OliverLetterer
Last active December 16, 2015 20:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save OliverLetterer/5494818 to your computer and use it in GitHub Desktop.
Save OliverLetterer/5494818 to your computer and use it in GitHub Desktop.
zsh script for automatically sending pull-request to CocoaPods/Specs:master without push access. make sure you have https://github.com/defunkt/hub installed
user="OliverLetterer"
master="CocoaPods"
pod-lint() {
pod spec lint --local --verbose
}
pod-release() {
git add -A && git commit -m "Release "$1"."
git tag $1
git push --tags
git push
pod push wecuyaca
}
pod-fork() {
here=$(pwd)
hub clone $master/Specs /tmp/Specs
cd /tmp/Specs && hub fork
rm -rf /tmp/Specs
cd $here && pod repo add $user http://github.com/$user/Specs.git
cd ~/.cocoapods/$user && git remote set-url origin git@github.com:$user/Specs.git
cd $here
unset here
}
pod-push() {
pod push $user
}
pod-pull-request() {
here=$(pwd)
cd ~/.cocoapods/$user && hub pull-request "Auto generated pull-request." -b $master:master -h $user:master
cd $here
unset here
rm -rf cd ~/.cocoapods/$user
}
pod-push-master() {
pod-fork
pod-push
pod-pull-request
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment