From: Lars Ingebrigtsen <larsi@gnus.org>
To: "Francesco Potortì" <pot@gnu.org>
Cc: 44617@debbugs.gnu.org
Subject: bug#44617: 26.3; diff-mode ignores diff-switches
Date: Sat, 14 Nov 2020 17:25:17 +0100 [thread overview]
Message-ID: <87361bzz0y.fsf@gnus.org> (raw)
In-Reply-To: <E1kdXvc-00EGhQ-St@tucano.isti.cnr.it> ("Francesco Potortì"'s message of "Fri, 13 Nov 2020 13:11:44 +0100")
Francesco Potortì <pot@gnu.org> writes:
> diff-mode relies on the diff-command variables defined in diff.el, but
> ignores diff-switches
>
> I think this is a bug
Do you mean the `diff-refresh-hunk' command? I does indeed ignore
`diff-switches', but that's because it tries to keep the style of the
diff consistent:
(defun diff-refresh-hunk (&optional ignore-whitespace)
"Re-diff the current hunk."
(interactive)
(let* ((char-offset (- (point) (diff-beginning-of-hunk t)))
(opt-type (pcase (char-after)
(?@ "-u")
(?* "-c")))
Which I think sounds like the correct design. What's the use case you
have for diff-switches where you'd want this command to heed diff-switches?
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
next prev parent reply other threads:[~2020-11-14 16:25 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-13 12:11 bug#44617: 26.3; diff-mode ignores diff-switches Francesco Potortì
2020-11-13 16:11 ` Unknown
2020-11-13 16:31 ` Unknown
2020-11-13 16:31 ` Unknown
2020-11-14 16:25 ` Lars Ingebrigtsen [this message]
2020-12-05 21:05 ` Francesco Potortì
2020-12-06 13:51 ` Lars Ingebrigtsen
2020-12-06 23:39 ` Francesco Potortì
2020-12-06 23:41 ` Lars Ingebrigtsen
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87361bzz0y.fsf@gnus.org \
--to=larsi@gnus.org \
--cc=44617@debbugs.gnu.org \
--cc=pot@gnu.org \
/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.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).