Git development
 help / color / mirror / Atom feed
From: "Alessio Attilio via GitGitGadget" <gitgitgadget@gmail.com>
To: git@vger.kernel.org
Cc: Johannes Schindelin <johannes.schindelin@gmx.de>,
	Alessio Attilio <attilio.alessio@protonmail.com>
Subject: [PATCH 0/4] rebase: support --whitespace=fix with --interactive
Date: Mon, 30 Nov 2026 00:01:21 +0000	[thread overview]
Message-ID: <pull.2511.git.git.1795996885.gitgitgadget@gmail.com> (raw)

The apply backend implements --whitespace=fix through git apply, which
prevents users from combining it with interactive rebases and other
merge-backend features. Teach merge replay to compare whitespace-normalized
records, then fix only lines introduced by replay using the path's
whitespace rules. Keep other whitespace actions on the apply backend.

Tests cover interactive replay, attributes, existing whitespace, added
files, end-of-file handling, and unsupported actions.

Closes gitgitgadget/git#1472

Alessio Attilio (4):
  xdiff: support transformed records in merge matching
  merge-ort: fix whitespace in replayed changes
  rebase: route whitespace fixes through the selected backend
  rebase: test whitespace fixes with the merge backend

 Documentation/git-rebase.adoc          |   6 +-
 builtin/rebase.c                       |  55 +++++++-
 contrib/completion/git-completion.bash |   2 +-
 merge-ll.c                             | 182 ++++++++++++++++++++++++-
 merge-ll.h                             |   5 +
 merge-ort.c                            |  52 +++++++
 merge-ort.h                            |   1 +
 t/t3417-rebase-whitespace-fix.sh       | 163 ++++++++++++++++++++++
 t/t3422-rebase-incompatible-options.sh |  17 ++-
 xdiff/xdiff.h                          |   4 +
 xdiff/xmerge.c                         |  16 +--
 xdiff/xprepare.c                       |  57 ++++++--
 xdiff/xtypes.h                         |   2 +
 xdiff/xutils.c                         |  14 ++
 xdiff/xutils.h                         |   2 +
 15 files changed, 547 insertions(+), 31 deletions(-)


base-commit: acba8bf9753134d9bde89f94369f775838a8c5fe
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-git-2511%2Fkairosci%2Fds%2Frebase-whitespace-fix-merge-v1
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-git-2511/kairosci/ds/rebase-whitespace-fix-merge-v1
Pull-Request: https://github.com/git/git/pull/2511
-- 
gitgitgadget

             reply	other threads:[~2026-11-30  0:01 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-30  0:01 Alessio Attilio via GitGitGadget [this message]
2026-11-30  0:01 ` [PATCH 1/4] xdiff: support transformed records in merge matching Alessio Attilio via GitGitGadget
2026-11-30  0:01 ` [PATCH 2/4] merge-ort: fix whitespace in replayed changes Alessio Attilio via GitGitGadget
2026-11-30  0:01 ` [PATCH 3/4] rebase: route whitespace fixes through the selected backend Alessio Attilio via GitGitGadget
2026-11-30  0:01 ` [PATCH 4/4] rebase: test whitespace fixes with the merge backend Alessio Attilio via GitGitGadget

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=pull.2511.git.git.1795996885.gitgitgadget@gmail.com \
    --to=gitgitgadget@gmail.com \
    --cc=attilio.alessio@protonmail.com \
    --cc=git@vger.kernel.org \
    --cc=johannes.schindelin@gmx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox