Created
January 9, 2015 19:41
-
-
Save xiian/4998c569b5684af026d2 to your computer and use it in GitHub Desktop.
Set up all existing branches to rebase instead of merge
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 | |
git config branch.autosetuprebase always; | |
for BRANCH in `git for-each-ref --format='%(refname)' refs/heads/ | sed 's~refs/heads/~~g'`; do | |
git config branch.$BRANCH.rebase true; | |
echo "$BRANCH now set up for rebasing" | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment