Skip to content

Instantly share code, notes, and snippets.

@jherran
Created February 27, 2015 22:27
Show Gist options
  • Select an option

  • Save jherran/f72b12001d3517092379 to your computer and use it in GitHub Desktop.

Select an option

Save jherran/f72b12001d3517092379 to your computer and use it in GitHub Desktop.
Git Hook post-checkout for running pod install after git checkout
#!/bin/bash
if [ -f Podfile ] && command -v pod install >/dev/null
then
OUT=$(unset GIT_DIR; exec pod install)
if echo "$OUT" | grep -q "Integrating client project"
then
echo "$OUT"
true
else
echo "$OUT" >&2
fi
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment