Allow '-' and '_' in log-edit field names.

* magit.el (magit-log-header-end, magit-log-edit-get-fields): Here.
This commit is contained in:
Marius Vollmer 2009-02-20 01:15:26 +02:00
parent 3efeed124e
commit a78f8b6019

View file

@ -2164,7 +2164,7 @@ Prefix arg means justify as well."
(save-excursion (save-excursion
(set-buffer buf) (set-buffer buf)
(goto-char (point-min)) (goto-char (point-min))
(while (looking-at "^\\([A-Za-z0-9]+\\): *\\(.*\\)$") (while (looking-at "^\\([A-Za-z0-9-_]+\\): *\\(.*\\)$")
(setq result (acons (intern (downcase (match-string 1))) (setq result (acons (intern (downcase (match-string 1)))
(match-string 2) (match-string 2)
result)) result))
@ -2178,7 +2178,7 @@ Prefix arg means justify as well."
(save-excursion (save-excursion
(set-buffer buf) (set-buffer buf)
(goto-char (point-min)) (goto-char (point-min))
(if (search-forward-regexp (format "^\\([A-Za-z0-9]+:.*\n\\)+%s" (if (search-forward-regexp (format "^\\([A-Za-z0-9-_]+:.*\n\\)+%s"
(regexp-quote magit-log-header-end)) (regexp-quote magit-log-header-end))
nil t) nil t)
(delete-region (match-beginning 0) (match-end 0))) (delete-region (match-beginning 0) (match-end 0)))