1
0
mirror of https://github.com/git/git.git synced 2024-11-19 04:04:17 +01:00

git svn: stop using rebase --preserve-merges

We deprecated `--preserve-merges` in favor of `--rebase-merges`; Let's
reflect that in `git svn`.

Note: Even when the user asks for `--preserve-merges`, we now silently
pass `--rebase-merges` to `git rebase` instead. Technically, this is a
change of behavior. But practically, `git svn` only ever asks for a
non-interactive rebase, and `--preserve-merges` and `--rebase-merges`
are on par with regard to that.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Acked-by: Eric Wong <e@80x24.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Johannes Schindelin 2019-11-22 22:59:29 +00:00 committed by Junio C Hamano
parent d9f6f3b619
commit ea8b7be147
2 changed files with 7 additions and 5 deletions

@ -677,7 +677,8 @@ config key: svn.authorsProg
-s<strategy>::
--strategy=<strategy>::
-p::
--preserve-merges::
--rebase-merges::
--preserve-merges (DEPRECATED)::
These are only used with the 'dcommit' and 'rebase' commands.
+
Passed directly to 'git rebase' when using 'dcommit' if a

@ -110,7 +110,7 @@ my ($_stdin, $_help, $_edit,
$_template, $_shared,
$_version, $_fetch_all, $_no_rebase, $_fetch_parent,
$_before, $_after,
$_merge, $_strategy, $_preserve_merges, $_dry_run, $_parents, $_local,
$_merge, $_strategy, $_rebase_merges, $_dry_run, $_parents, $_local,
$_prefix, $_no_checkout, $_url, $_verbose,
$_commit_url, $_tag, $_merge_info, $_interactive, $_set_svn_props);
@ -270,7 +270,8 @@ my %cmd = (
'local|l' => \$_local,
'fetch-all|all' => \$_fetch_all,
'dry-run|n' => \$_dry_run,
'preserve-merges|p' => \$_preserve_merges,
'rebase-merges|p' => \$_rebase_merges,
'preserve-merges|p' => \$_rebase_merges,
%fc_opts } ],
'commit-diff' => [ \&cmd_commit_diff,
'Commit a diff between two trees',
@ -1054,7 +1055,7 @@ sub cmd_dcommit {
'If you are attempting to commit ',
"merges, try running:\n\t",
'git rebase --interactive',
'--preserve-merges ',
'--rebase-merges ',
$gs->refname,
"\nBefore dcommitting";
}
@ -1717,7 +1718,7 @@ sub rebase_cmd {
push @cmd, '-v' if $_verbose;
push @cmd, qw/--merge/ if $_merge;
push @cmd, "--strategy=$_strategy" if $_strategy;
push @cmd, "--preserve-merges" if $_preserve_merges;
push @cmd, "--rebase-merges" if $_rebase_merges;
@cmd;
}