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

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

[elpa] externals/denote 0daf97be00 3/3: Make denote-link-description-for


From: ELPA Syncer
Subject: [elpa] externals/denote 0daf97be00 3/3: Make denote-link-description-format accept %T for file name title only
Date: Wed, 6 Nov 2024 03:57:44 -0500 (EST)

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

    Make denote-link-description-format accept %T for file name title only
---
 README.org | 3 ++-
 denote.el  | 4 +++-
 2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/README.org b/README.org
index 2baec7e48f..6661795b97 100644
--- a/README.org
+++ b/README.org
@@ -3364,7 +3364,8 @@ the note (with the signature if present).
 
 If the value is a string, it treats specially the following specifiers:
 
-- The =%t= is the Denote =TITLE= of the file.
+- The =%t= is the Denote =TITLE= in the front matter or the file name.
+- The =%T= is the Denote =TITLE= in the file name.
 - The =%i= is the Denote =IDENTIFIER= of the file.
 - The =%d= is the same as =%i= (=DATE= mnemonic).
 - The =%s= is the Denote =SIGNATURE= of the file.
diff --git a/denote.el b/denote.el
index bdd4f30a8c..94d1cbfda5 100644
--- a/denote.el
+++ b/denote.el
@@ -879,7 +879,8 @@ the note (with the signature if present).
 
 If the value is a string, it treats specially the following specifiers:
 
-- The %t is the Denote TITLE of the file.
+- The %t is the Denote TITLE in the front matter or the file name.
+- The %T is the Denote TITLE in the file name.
 - The %i is the Denote IDENTIFIER of the file.
 - The %d is the same as %i (DATE mnemonic).
 - The %s is the Denote SIGNATURE of the file.
@@ -4150,6 +4151,7 @@ active, use it as the description."
                                     ((denote-retrieve-front-matter-title-value 
file (denote-filetype-heuristics file)))
                                     ((denote-retrieve-filename-title file))
                                     (t  "")))
+                          (cons ?T (or (denote-retrieve-filename-title file) 
""))
                           (cons ?i (or (denote-retrieve-filename-identifier 
file) ""))
                           (cons ?d (or (denote-retrieve-filename-identifier 
file) ""))
                           (cons ?s (or (denote-retrieve-filename-signature 
file) ""))



reply via email to

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