From: Rohit Ashiwal Date: Fri, 01 Nov 2019 13:59:58 GMT Subject: [PATCH v5 1/6] rebase -i: add --ignore-whitespace flag Message-ID: <20191101140003.13960-2-rohit.ashiwal265@gmail.com> In-Reply-To: <20191101140003.13960-1-rohit.ashiwal265@gmail.com> There are two backends available for rebasing, viz, the am and the interactive. Naturally, there shall be some features that are implemented in one but not in the other. One such flag is --ignore-whitespace which indicates merge mechanism to treat lines with only whitespace changes as unchanged. Wire the interactive rebase to also understand the --ignore-whitespace flag by translating it to -Xignore-space-change. Signed-off-by: Rohit Ashiwal --- Documentation/git-rebase.txt | 12 ++++- builtin/rebase.c | 19 ++++++-- t/t3422-rebase-incompatible-options.sh | 1 - t/t3433-rebase-options-compatibility.sh | 65 +++++++++++++++++++++++++ 4 files changed, 90 insertions(+), 7 deletions(-) create mode 100755 t/t3433-rebase-options-compatibility.sh diff --git a/Documentation/git-rebase.txt b/Documentation/git-rebase.txt index 639a4179d1..b4de299e6f 100644 --- a/Documentation/git-rebase.txt +++ b/Documentation/git-rebase.txt @@ -393,8 +393,16 @@ your branch contains commits which were dropped, this option can be used with `--keep-base` in order to drop those commits from your branch. --ignore-whitespace:: + Behaves differently depending on which backend is selected. ++ +'am' backend: When applying a patch, ignore changes in whitespace in +context lines if necessary. ++ +'interactive' backend: Treat lines with only whitespace changes as +unchanged for the sake of a three-way merge. + --whitespace=