Browse Source

git-svn: fail on rebase if we are unable to find a ref to rebase against

If we're on an invalid HEAD, we should detect this and avoid
attempting to continue.

Signed-off-by: Eric Wong <normalperson@yhbt.net>
Signed-off-by: Junio C Hamano <junkio@cox.net>
maint
Eric Wong 18 years ago committed by Junio C Hamano
parent
commit
d6bad6610a
  1. 3
      git-svn.perl

3
git-svn.perl

@ -435,6 +435,9 @@ sub cmd_rebase { @@ -435,6 +435,9 @@ sub cmd_rebase {
}

my $gs = Git::SVN->find_by_url($url);
unless ($gs) {
die "Unable to determine remote information from URL: $url\n";
}
if (command(qw/diff-index HEAD --/)) {
print STDERR "Cannot rebase with uncommited changes:\n";
command_noisy('status');

Loading…
Cancel
Save