unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#13886: 24.3; vc-annotate won't show the log entry with git backend and hidden annotatation
@ 2013-03-06  2:37 E Sabof
  2013-11-25  2:30 ` Dmitry Gutov
  0 siblings, 1 reply; 3+ messages in thread
From: E Sabof @ 2013-03-06  2:37 UTC (permalink / raw)
  To: 13886

[-- Attachment #1: Type: text/plain, Size: 884 bytes --]

While in vc-annotate mode, with a git backend, if one hides the
annotations with vc-annotate-toggle-annotation-visiblity, and
tries to run vc-annotate-show-log-revision-at-line, it will display the
message "Cannot extract revision number from the current line".
Fixable by changing (move-beginning-of-line 1) to (forward-line 0) here:

(defun vc-git-annotate-extract-revision-at-line ()
  (save-excursion
    (forward-line 0)
    (when (looking-at "\\([0-9a-f^][0-9a-f]+\\) \\(\\([^(]+\\) \\)?")
      (let ((revision (match-string-no-properties 1)))
(if (match-beginning 2)
    (let ((fname (match-string-no-properties 3)))
      ;; Remove trailing whitespace from the file name.
      (when (string-match " +\\'" fname)
(setq fname (substring fname 0 (match-beginning 0))))
      (cons revision
    (expand-file-name fname (vc-git-root default-directory))))
  revision)))))

Evgeni

[-- Attachment #2: Type: text/html, Size: 1570 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#13886: 24.3; vc-annotate won't show the log entry with git backend and hidden annotatation
  2013-03-06  2:37 bug#13886: 24.3; vc-annotate won't show the log entry with git backend and hidden annotatation E Sabof
@ 2013-11-25  2:30 ` Dmitry Gutov
  2013-11-26 17:14   ` E Sabof
  0 siblings, 1 reply; 3+ messages in thread
From: Dmitry Gutov @ 2013-11-25  2:30 UTC (permalink / raw)
  To: E Sabof; +Cc: 13886-done

Version: 24.4

Thanks for the report, fixed in 115219.

Though I've changed it to use `beginning-of-line' for better
consistency, because implementations of this command in other backends
do that.





^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#13886: 24.3; vc-annotate won't show the log entry with git backend and hidden annotatation
  2013-11-25  2:30 ` Dmitry Gutov
@ 2013-11-26 17:14   ` E Sabof
  0 siblings, 0 replies; 3+ messages in thread
From: E Sabof @ 2013-11-26 17:14 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: 13886-done

[-- Attachment #1: Type: text/plain, Size: 346 bytes --]

Sounds good, if it still fixes the problem. Thanks!

Evgeni


On Mon, Nov 25, 2013 at 2:30 AM, Dmitry Gutov <dgutov@yandex.ru> wrote:

> Version: 24.4
>
> Thanks for the report, fixed in 115219.
>
> Though I've changed it to use `beginning-of-line' for better
> consistency, because implementations of this command in other backends
> do that.
>

[-- Attachment #2: Type: text/html, Size: 695 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-11-26 17:14 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-03-06  2:37 bug#13886: 24.3; vc-annotate won't show the log entry with git backend and hidden annotatation E Sabof
2013-11-25  2:30 ` Dmitry Gutov
2013-11-26 17:14   ` E Sabof

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).