unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Ramesh Nedunchezian <rameshnedunchezian@outlook.com>
To: 47566@debbugs.gnu.org
Subject: bug#47566: 28.0.50; diff-hl should use `repeat-mode' ... and not `smartrep'
Date: Fri, 2 Apr 2021 11:10:13 +0530	[thread overview]
Message-ID: <TY2PR0101MB36932D978661080B581457C6DA7A9@TY2PR0101MB3693.apcprd01.prod.exchangelabs.com> (raw)


28.0.50; diff-hl should use `repeat-mode' ... and not `smartrep'.

Commentary in `diff-hl' says

    ;; `diff-hl-mode' highlights uncommitted changes on the side of the
    ;; window (using the fringe, by default), allows you to jump between
    ;; the hunks and revert them selectively.

    ;; Provided commands:
    ;;
    ;; `diff-hl-diff-goto-hunk'  C-x v =
    ;; `diff-hl-revert-hunk'     C-x v n
    ;; `diff-hl-previous-hunk'   C-x v [
    ;; `diff-hl-next-hunk'       C-x v ]
    ;;
    ;; The mode takes advantage of `smartrep' if it is installed.

FWIW, `smartrep' is not part of GNU Emacs or GNU ELPA but available
elsewhere.  (I install it via MELPA)

Now, that `repeat-mode' is part of GNU Emacs, I think this dependency
on `smartrep' can be removed.

FWIW, this is what I have in my `.emacs'.

    (progn
      (defvar diff-hl--repeat-map
	(let
	    ((map
	      (make-sparse-keymap)))
	  map))
      (message "Installed %s" 'diff-hl--repeat-map)
      (cl-loop for
	       (cmd . key)
	       in
	       '((diff-hl-diff-goto-hunk . "=")
		 (diff-hl-revert-hunk . "n")
		 (diff-hl-previous-hunk . "[")
		 (diff-hl-next-hunk . "]"))
	       do
	       (define-key diff-hl--repeat-map key cmd)
	       (put cmd 'repeat-map 'diff-hl--repeat-map)))

----------------

In GNU Emacs 28.0.50 (build 3, x86_64-pc-linux-gnu, GTK+ Version 3.24.24, cairo version 1.16.0)
 of 2021-03-20 built on debian
Repository revision: 31544bc908d35bff513450bc4bea1d0283a7ddb0
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12010000
System Description: Debian GNU/Linux bullseye/sid





             reply	other threads:[~2021-04-02  5:40 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-02  5:40 Ramesh Nedunchezian [this message]
2021-04-03 22:08 ` bug#47566: 28.0.50; diff-hl should use `repeat-mode' ... and not `smartrep' Dmitry Gutov
2021-04-05 20:43   ` Juri Linkov
2021-04-06 22:44     ` Dmitry Gutov
2021-04-08 18:57       ` Juri Linkov
2021-04-10  1:40         ` Dmitry Gutov
2021-04-10  8:38           ` Ramesh Nedunchezian
2021-04-10 22:59             ` Juri Linkov
2021-04-11  6:48               ` Ramesh Nedunchezian
2021-04-11 22:51                 ` Juri Linkov
2021-04-12 16:16                 ` Juri Linkov
2021-04-10 22:58           ` Juri Linkov
2021-04-10 23:27             ` Dmitry Gutov
2021-04-12 16:17               ` Juri Linkov
2021-04-13 23:54                 ` Dmitry Gutov
2021-04-14  7:14                   ` Kévin Le Gouguec
2021-04-14 18:10                     ` Juri Linkov
2021-04-14 19:12                       ` Kévin Le Gouguec
2021-04-14 19:52                         ` Juri Linkov
2021-04-14 20:21                           ` Juri Linkov
2021-04-14 20:48                           ` Kévin Le Gouguec
2021-04-14 21:58                             ` Juri Linkov
2021-04-14 23:35                       ` Dmitry Gutov
2021-11-14 20:25         ` Juri Linkov
2021-11-15  5:26           ` Lars Ingebrigtsen
2021-11-15 17:40             ` Juri Linkov

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=TY2PR0101MB36932D978661080B581457C6DA7A9@TY2PR0101MB3693.apcprd01.prod.exchangelabs.com \
    --to=rameshnedunchezian@outlook.com \
    --cc=47566@debbugs.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).