diff mbox series

[bug#44547,v3,1/2] etc: snippets: Fix package name extraction.

Message ID 20201121111125.30737-1-mail@ambrevar.xyz
State Accepted
Headers show
Series [bug#44547,v3,1/2] etc: snippets: Fix package name extraction. | expand


Context Check Description
cbaines/submitting builds success
cbaines/submitting builds success
cbaines/comparison success View comparision
cbaines/git branch success View Git branch
cbaines/applying patch success View Laminar job
cbaines/issue success View issue

Commit Message

Pierre Neidhardt Nov. 21, 2020, 11:11 a.m. UTC
* etc/snippets/text-mode/guix-commit-message-add-package: Properly extract
name when the diff contains a very short `define-public ...` above the actual
new package.  This can happen when the above package is a small inherited
definition or cl/ecl package.
 etc/snippets/text-mode/guix-commit-message-add-package | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series


diff --git a/etc/snippets/text-mode/guix-commit-message-add-package b/etc/snippets/text-mode/guix-commit-message-add-package
index 0dff2cbcf5..e54a06de7e 100644
--- a/etc/snippets/text-mode/guix-commit-message-add-package
+++ b/etc/snippets/text-mode/guix-commit-message-add-package
@@ -7,7 +7,7 @@  gnu: Add ${1:`(with-temp-buffer
                 (magit-git-wash #'magit-diff-wash-diffs
                   "diff" "--staged")
-                (when (search-forward "(define-public " nil 'noerror)
+                (when (search-forward "+(define-public " nil 'noerror)
                   (thing-at-point 'sexp 'no-properties)))`}.
 * `(car (magit-staged-files))` ($1): New variable.
\ No newline at end of file