Abstract plain text front matter delimiter

This commit is contained in:
Protesilaos Stavrou 2022-06-11 09:21:25 +03:00
parent bca23b3e3d
commit c5a5748594
No known key found for this signature in database
GPG key ID: 99BD6459CD5CA3EA

View file

@ -395,7 +395,13 @@ tags: %s
identifier: %s
%s\n\n"
"Plain text front matter value for `format'.
Read `denote-org-front-matter' for the technicalities.")
Read `denote-org-front-matter' for the technicalities of the
first four specifiers this variable accepts. The fifth specifier
this specific to this variable: it expect a delimiter:
`denote-text-front-matter-delimiter'.")
(defvar denote-text-front-matter-delimiter (make-string 27 ?-)
"Final delimiter for plain text front matter.")
(defvar denote-org-front-matter
"#+title: %s
@ -419,7 +425,7 @@ TITLE, DATE, KEYWORDS, FILENAME, ID are all strings which are
(pcase denote-file-type
('markdown-toml (format denote-tml-front-matter title date kw-toml id))
('markdown-yaml (format denote-yaml-front-matter title date kw-space id))
('text (format denote-text-front-matter title date kw-space id (make-string 27 ?-)))
('text (format denote-text-front-matter title date kw-space id denote-text-front-matter-delimiter))
(_ (format denote-org-front-matter title date kw-space id)))))
(defun denote--path (title keywords)