From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS31976 209.132.180.0/23 X-Spam-Status: No, score=-3.9 required=3.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_NONE shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by dcvr.yhbt.net (Postfix) with ESMTP id 925591F461 for ; Sat, 7 Sep 2019 11:51:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1733054AbfIGLvB (ORCPT ); Sat, 7 Sep 2019 07:51:01 -0400 Received: from mail-pf1-f194.google.com ([209.85.210.194]:42596 "EHLO mail-pf1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728129AbfIGLvB (ORCPT ); Sat, 7 Sep 2019 07:51:01 -0400 Received: by mail-pf1-f194.google.com with SMTP id w22so6285104pfi.9 for ; Sat, 07 Sep 2019 04:51:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=bfLkpI+MxJTsj1WksAPKdLj9fbvrvbTAEj39Xk+0BSw=; b=diSzemuwM25Qp71VT/zCTcXBmB7OhyKroB6JBHIsnIux/hPFgyJpX4xvhR3B2JdKH7 f6yp9wmqt/JXGkwa1jR0pO1QIZXcCr8FVmCdYXhlH2fjo1PTYn3fKUZIhqSqFlyjAWrg 4+NoT/iaRksH+LGxJI25yP5Rq0cNi5jmCbUPEewT0zqNkA7CNzW8aEkuoxJXQGvdCth/ GB71hZySx49/OZ/QaVNvG772Bgv9qaXmyPvygwO77poM4l031vBUaR+a5nhsy649PEOQ ls4yIqroTQWak16zYPuUTgVM3NZ8Q+eN30kzmW+tlYSsd0RYRospaTtHZw2ndzB580Ah yN0A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=bfLkpI+MxJTsj1WksAPKdLj9fbvrvbTAEj39Xk+0BSw=; b=H+zRgIOUY4PFbDOLn2jY3oCKJPl5H4JkIZzmWBH3G37otJKdo8wI1p/W9hZR/Olhwx /NPaZt4yNAdulkTW+RNPVD37DlC6cSAcIifpDJLWv/gGXwvRiHXFCJIUrMpZpB09zXwk qMMtH9DyNNugsKHZiIGv2bGEHdIbqmZwZ9k8FCEslrafjLMCsVjfIWC/Hf8/1sRi9++F bh7pUCRM+XwsYUZ4IlLp3Jkhf2xupHcNNLAb3IxEvbfKyK6yNbhgbLtxhLmmnsVmK/Wz 2uGhb9LA2BUzZ0VwK5yOcjy+EHm/VcXg6AtqM3EYYEjd6o8aG/XCywF64WmFTgUXR2nK NBqA== X-Gm-Message-State: APjAAAVh1XcA8SHSgIvpZzJlHnNVGnIMME1esn2+J44VSUOkUiQHskbJ dcs9Eo8tIi9cPFMk6U7Rb/4= X-Google-Smtp-Source: APXvYqwvlUvL/cPYHIUKbW6AKdhskwOkj7k8GhZbWkS0Aq8lIiwR6TNSMcrpB4xyaKpoaSFIQ+X6ew== X-Received: by 2002:a63:2148:: with SMTP id s8mr11998104pgm.336.1567857059714; Sat, 07 Sep 2019 04:50:59 -0700 (PDT) Received: from ar135.mshome.net ([103.37.200.225]) by smtp.gmail.com with ESMTPSA id a11sm18134792pfg.94.2019.09.07.04.50.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 07 Sep 2019 04:50:59 -0700 (PDT) From: Rohit Ashiwal To: rohit.ashiwal265@gmail.com Cc: Johannes.Schindelin@gmx.de, git@vger.kernel.org, gitster@pobox.com, martin.agren@gmail.com, newren@gmail.com, phillip.wood123@gmail.com, t.gummerer@gmail.com Subject: [PATCH v4 1/6] rebase -i: add --ignore-whitespace flag Date: Sat, 7 Sep 2019 17:20:29 +0530 Message-Id: <20190907115034.14933-2-rohit.ashiwal265@gmail.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190907115034.14933-1-rohit.ashiwal265@gmail.com> References: <20190806173638.17510-1-rohit.ashiwal265@gmail.com> <20190907115034.14933-1-rohit.ashiwal265@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org 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 | 13 ++++- builtin/rebase.c | 22 +++++++-- t/t3422-rebase-incompatible-options.sh | 1 - t/t3433-rebase-options-compatibility.sh | 65 +++++++++++++++++++++++++ 4 files changed, 94 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 6156609cf7..873eb5768c 100644 --- a/Documentation/git-rebase.txt +++ b/Documentation/git-rebase.txt @@ -371,8 +371,16 @@ If either or --root is given on the command line, then the default is `--no-fork-point`, otherwise the default is `--fork-point`. --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=