{"thread":{"id":"26345","subject":"[PATCH 2/2] rebase: give a better error message for bogus branch","startedAt":"2011-01-27T00:27:11Z","lastAt":"2011-01-27T01:27:19Z","messageCount":2,"participants":["Jeff King","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":2},"messages":[{"id":"159934","messageId":"20110127002711.GB32711@sigill.intra.peff.net","threadId":"26345","inReplyTo":null,"subject":"[PATCH 2/2] rebase: give a better error message for bogus branch","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2011-01-27T00:27:11Z","receivedAt":"2011-01-27T00:27:11Z","isPatch":true,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"When you give a non-existent branch to git-rebase, it spits\nout the usage. This can be confusing, since you may\nunderstand the usage just fine, but simply have made a\nmistake in the branch name.\n\nBefore:\n\n  $ git rebase origin bogus\n  Usage: git rebase ...\n\nAfter:\n\n  $ git rebase origin bogus\n  fatal: no such branch: bogus\n  Usage: git rebase ...\n\nSigned-off-by: Jeff King <peff@peff.net>\n---\n git-rebase.sh |    1 +\n 1 files changed, 1 insertions(+), 0 deletions(-)\n\ndiff --git a/git-rebase.sh b/git-rebase.sh\nindex 345b18c..cbb0ea9 100755\n--- a/git-rebase.sh\n+++ b/git-rebase.sh\n@@ -482,6 +482,7 @@ case \"$#\" in\n \tthen\n \t\thead_name=\"detached HEAD\"\n \telse\n+\t\techo >&2 \"fatal: no such branch: $1\"\n \t\tusage\n \tfi\n \t;;\n-- \n1.7.4.rc3.5.g8354b\n"},{"id":"159937","messageId":"7v39ofi1ag.fsf@alter.siamese.dyndns.org","threadId":"26345","inReplyTo":"20110127002711.GB32711@sigill.intra.peff.net","subject":"Re: [PATCH 2/2] rebase: give a better error message for bogus branch","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2011-01-27T01:27:19Z","receivedAt":"2011-01-27T01:27:19Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Thanks, both patches look very sensible.\n"}]}