rebase: use the new git-rebase--preserve-merges.sh
commit6d98d0c018cc8008af386f19a43a8b823a5a08d8
authorAlban Gruin <alban.gruin@gmail.com>
Mon, 28 May 2018 12:34:21 +0000 (28 14:34 +0200)
committerJunio C Hamano <gitster@pobox.com>
Fri, 1 Jun 2018 00:34:48 +0000 (1 09:34 +0900)
tree585532062b4a743babe1ead147221653af6c347c
parentef64bb328df9c131c6c454ad65169fa3972da512
rebase: use the new git-rebase--preserve-merges.sh

Create a new type of rebase, "preserve-merges", used when rebase is
called with -p.

Before that, the type for preserve-merges was "interactive", and some
places of this script compared $type to "interactive". Instead, the code
now checks if $interactive_rebase is empty or not, as it is set to
"explicit" when calling an interactive rebase (and, possibly, one of its
submodes), and "implied" when calling one of its
submodes (eg. preserve-merges) *without* interactive rebase.

It also detects the presence of the directory "$merge_dir"/rewritten
left by the preserve-merges script when calling rebase --continue,
--skip, etc., and, if it exists, sets the rebase mode to
preserve-merges. In this case, interactive_rebase is set to "explicit",
as "implied" would break some tests.

Signed-off-by: Alban Gruin <alban.gruin@gmail.com>
git-rebase.sh