[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/agitate 8459e26050 45/67: Add helper prompt for commit
From: |
ELPA Syncer |
Subject: |
[elpa] externals/agitate 8459e26050 45/67: Add helper prompt for commit log completion |
Date: |
Wed, 28 Sep 2022 16:57:29 -0400 (EDT) |
branch: externals/agitate
commit 8459e26050046ca7dd48528db1c1e0511c1661a7
Author: Protesilaos Stavrou <info@protesilaos.com>
Commit: Protesilaos Stavrou <info@protesilaos.com>
Add helper prompt for commit log completion
---
agitate.el | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/agitate.el b/agitate.el
index 9ca24f4b5d..f4bdd0f4db 100644
--- a/agitate.el
+++ b/agitate.el
@@ -265,6 +265,20 @@ to the text at point."
(when (string-match "\\b\\([0-9a-z]+\\) " string)
(match-string 1 string)))
+(defun agitate--vc-git-commit-prompt (&optional file)
+ "Prompt for Git commit and return it as a string.
+With optional FILE, limit the commits to those pertinent to it."
+ (let ((default-directory (vc-root-dir)))
+ (if file
+ (completing-read
+ (format "Select revision of `%s': " file)
+ (process-lines vc-git-program "log" "--oneline" file)
+ nil t)
+ (completing-read
+ "Select revision: "
+ (process-lines vc-git-program "log" "--oneline" "--")
+ nil t))))
+
;;;###autoload
(defun agitate-vc-git-grep (regexp)
"Run `git-grep(1)' for REGEXP in `vc-root-dir'.
- [elpa] externals/agitate de2094a2f5 53/67: Placate the compiler, (continued)
- [elpa] externals/agitate de2094a2f5 53/67: Placate the compiler, ELPA Syncer, 2022/09/28
- [elpa] externals/agitate 50251c7eff 64/67: Add agitate-log-view-kill-revision-expanded cmd, ELPA Syncer, 2022/09/28
- [elpa] externals/agitate 60dea993b9 25/67: Add COPYING GNU General Public License, ELPA Syncer, 2022/09/28
- [elpa] externals/agitate a2173cf82c 39/67: Implement conventional commits; refine emoji commits, ELPA Syncer, 2022/09/28
- [elpa] externals/agitate acaa1868d0 30/67: Move log-view section further down, ELPA Syncer, 2022/09/28
- [elpa] externals/agitate 2b8a593a5d 38/67: Add missing backronym from README.md, ELPA Syncer, 2022/09/28
- [elpa] externals/agitate 52c9968e5f 19/67: Refine agitate-vc-git-push doc string, ELPA Syncer, 2022/09/28
- [elpa] externals/agitate b7a51e04d2 18/67: Adjust indentation, ELPA Syncer, 2022/09/28
- [elpa] externals/agitate f29bc8e32a 21/67: Reorder some functions, ELPA Syncer, 2022/09/28
- [elpa] externals/agitate 3185f2becd 50/67: Clarify word in agitate-vc-git-grep doc string, ELPA Syncer, 2022/09/28
- [elpa] externals/agitate 8459e26050 45/67: Add helper prompt for commit log completion,
ELPA Syncer <=