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

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

[elpa] externals/denote bca23b3e3d 115/355: Clarify how front matter var


From: ELPA Syncer
Subject: [elpa] externals/denote bca23b3e3d 115/355: Clarify how front matter variables are used
Date: Sun, 26 Jun 2022 23:58:11 -0400 (EDT)

branch: externals/denote
commit bca23b3e3de743e0f4ca69400e270181ffef487f
Author: Protesilaos Stavrou <info@protesilaos.com>
Commit: Protesilaos Stavrou <info@protesilaos.com>

    Clarify how front matter variables are used
    
    This "hidden option" lets the user do something like this (I prepend >
    to escape the #):
    
    >    (setq denote-org-front-matter
    >          ":PROPERTIES:
    >    :ID: %4$s
    >    :END:
    >    #+title:      %1$s
    >    #+date:       %2$s
    >    #+filetags:   %3$s
    >    #+identifier: %4$s
    >    \n")
    
    Ultimately though, it gives us more flexibility if we ever want to
    support extra features.
    
    One such feature is the ability to create links using the org-id.el
    library.  See issue 8 over at the GitHub mirror, with feedback from
    Kaushal Modi: <https://github.com/protesilaos/denote/issues/8>.
---
 denote.el | 15 +++++++++++----
 1 file changed, 11 insertions(+), 4 deletions(-)

diff --git a/denote.el b/denote.el
index 0e5022d31c..fa04d4274c 100644
--- a/denote.el
+++ b/denote.el
@@ -375,7 +375,8 @@ date       = %s
 tags       = %s
 identifier = %S
 +++\n\n"
-  "TOML front matter value for `format'.")
+  "TOML front matter value for `format'.
+Read `denote-org-front-matter' for the technicalities.")
 
 (defvar denote-yaml-front-matter
   "---
@@ -384,7 +385,8 @@ date:       %s
 tags:       %s
 identifier: %S
 ---\n\n"
-  "YAML front matter value for `format'.")
+  "YAML front matter value for `format'.
+Read `denote-org-front-matter' for the technicalities.")
 
 (defvar denote-text-front-matter
   "title:      %s
@@ -392,7 +394,8 @@ date:       %s
 tags:       %s
 identifier: %s
 %s\n\n"
-  "Plain text front matter value for `format'.")
+  "Plain text front matter value for `format'.
+Read `denote-org-front-matter' for the technicalities.")
 
 (defvar denote-org-front-matter
   "#+title:      %s
@@ -400,7 +403,11 @@ identifier: %s
 #+filetags:   %s
 #+identifier: %s
 \n"
-  "Org front matter value for `format'.")
+  "Org front matter value for `format'.
+The order of the arguments is TITLE, DATE, KEYWORDS, ID.  If you
+are an avdanced user who wants to edit this variable to affect
+how front matter is produced, consider using something like %2$s
+to control where Nth argument is placed.")
 
 (defun denote--file-meta-header (title date keywords id)
   "Front matter for new notes.



reply via email to

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