Skip to content

Commit

Permalink
git-svn: preserve uncommitted changes after dcommit
Browse files Browse the repository at this point in the history
Using dcommit could cause the user to lose uncommitted changes
during the reset --hard operation, so change it to reset --mixed.

If dcommit chooses the rebase path, then git-rebase will already
error out when local changes are made.

Signed-off-by: Eric Wong <normalperson@yhbt.net>
Signed-off-by: Junio C Hamano <junkio@cox.net>
  • Loading branch information
Eric Wong authored and Junio C Hamano committed Nov 23, 2006
1 parent e70dc78 commit 4769489
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion git-svn.perl
Original file line number Diff line number Diff line change
Expand Up @@ -623,7 +623,7 @@ sub dcommit {
} else {
print "No changes between current HEAD and $gs\n",
"Hard resetting to the latest $gs\n";
@finish = qw/reset --hard/;
@finish = qw/reset --mixed/;
}
sys('git', @finish, $gs);
}
Expand Down

0 comments on commit 4769489

Please sign in to comment.