emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/agitate 0b80819820 62/67: Refine regexp for git hash ex


From: ELPA Syncer
Subject: [elpa] externals/agitate 0b80819820 62/67: Refine regexp for git hash extraction
Date: Wed, 28 Sep 2022 16:57:30 -0400 (EDT)

branch: externals/agitate
commit 0b808198202f6bd09d64ec08dc83d3d0f0897dbe
Author: Protesilaos Stavrou <info@protesilaos.com>
Commit: Protesilaos Stavrou <info@protesilaos.com>

    Refine regexp for git hash extraction
---
 agitate.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/agitate.el b/agitate.el
index 88a22fe814..164d0fae73 100644
--- a/agitate.el
+++ b/agitate.el
@@ -234,7 +234,7 @@ to the text at point."
 
 (defun agitate--vc-git-get-hash-from-string (string)
   "Return commit hash from beginning of STRING."
-  (when (string-match "\\b\\([0-9a-z]+\\) " string)
+  (when (string-match "\\b\\([0-9a-z]+\\)\\(\s+\\)?" string)
     (match-string 1 string)))
 
 (defun agitate--vc-git-commit-prompt (&optional file long)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]