{"thread":{"id":"17874","subject":"[PATCH v2] disallow providing multiple upstream branches to rebase, pull --rebase","startedAt":"2009-02-18T13:44:02Z","lastAt":"2009-02-18T13:44:02Z","messageCount":1,"participants":["Jay Soffian"],"isPatch":true,"patchVersion":2,"patchTotal":null},"messages":[{"id":"105308","messageId":"1234964642-95381-1-git-send-email-jaysoffian@gmail.com","threadId":"17874","inReplyTo":null,"subject":"[PATCH v2] disallow providing multiple upstream branches to rebase, pull --rebase","fromName":"Jay Soffian","fromEmail":"jaysoffian@gmail.com","sentAt":"2009-02-18T13:44:02Z","receivedAt":"2009-02-18T13:44:02Z","isPatch":true,"sender":{"key":"jaysoffian@gmail.com","avatar":"https://avatars.githubusercontent.com/u/155970?v=4"},"body":"It does not make sense to provide multiple upstream branches to either\ngit pull --rebase, or to git rebase, so disallow both.\n\nSigned-off-by: Jay Soffian <jaysoffian@gmail.com>\n---\nThis time w/o breaking git rebase $UPSTREAM $BRANCH_TO_SWITCH_TO\n\n git-pull.sh   |    5 +++++\n git-rebase.sh |    1 +\n 2 files changed, 6 insertions(+), 0 deletions(-)\n\ndiff --git a/git-pull.sh b/git-pull.sh\nindex 2c7f432..25adddf 100755\n--- a/git-pull.sh\n+++ b/git-pull.sh\n@@ -171,6 +171,11 @@ case \"$merge_head\" in\n \t\techo >&2 \"Cannot merge multiple branches into empty head\"\n \t\texit 1\n \tfi\n+\tif test true = \"$rebase\"\n+\tthen\n+\t\techo >&2 \"Cannot rebase onto multiple branches\"\n+\t\texit 1\n+\tfi\n \t;;\n esac\n \ndiff --git a/git-rebase.sh b/git-rebase.sh\nindex 5d9a393..c2a9b1f 100755\n--- a/git-rebase.sh\n+++ b/git-rebase.sh\n@@ -319,6 +319,7 @@ do\n \tesac\n \tshift\n done\n+test $# -gt 2 && usage\n \n # Make sure we do not have $GIT_DIR/rebase-apply\n if test -z \"$do_merge\"\n-- \n1.6.2.rc1.218.g1b4fab\n"}]}