Pass underscore through in anchor string.

This commit is contained in:
Aaron Muir Hamilton 2018-12-13 04:08:33 +00:00
parent c0d1a8d40a
commit 1a9c49bf91

View File

@ -274,7 +274,7 @@ contextual information."
;;;; Table of contents ;;;; Table of contents
(defun org-gfm-anchor-from-title (title) (defun org-gfm-anchor-from-title (title)
(replace-regexp-in-string "[^a-z\-]" "" (downcase (replace-regexp-in-string "[ ]" "-" title)))) (replace-regexp-in-string "[^a-z\-_]" "" (downcase (replace-regexp-in-string "[ ]" "-" title))))
(defun org-gfm-anchor-from-headline (headline) (defun org-gfm-anchor-from-headline (headline)
(org-gfm-anchor-from-title (org-export-data (org-export-get-alt-title headline info) info))) (org-gfm-anchor-from-title (org-export-data (org-export-get-alt-title headline info) info)))