branch: elpa/eldoc-diffstat
commit eb3a9e7f3aad9f531bc8e934555b55e90bcc11c7
Author: Johann Klähn <[email protected]>
Commit: Johann Klähn <[email protected]>
Add support for git-rebase-mode
---
eldoc-diffstat.el | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/eldoc-diffstat.el b/eldoc-diffstat.el
index 83b90b5c76..222381a1fe 100644
--- a/eldoc-diffstat.el
+++ b/eldoc-diffstat.el
@@ -39,6 +39,7 @@
;;; Code:
(require 'ansi-color)
+(require 'eieio)
(defvar eldoc-diffstat--process nil
"The latest async process used for fetching diffstat information.
@@ -83,6 +84,12 @@ a string identifying the specific revision."
((when-let (((fboundp 'magit-commit-at-point))
(revision (magit-commit-at-point)))
(cons 'Git revision)))
+ ((and (derived-mode-p 'git-rebase-mode)
+ (fboundp 'git-rebase-current-line)
+ (with-slots (action-type target)
+ (git-rebase-current-line)
+ (and (eq action-type 'commit)
+ (cons 'Git target)))))
((and (derived-mode-p 'vc-annotate-mode)
(boundp 'vc-annotate-backend)
(fboundp 'vc-annotate-extract-revision-at-line))