[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/denote 0ac3680b15 1/5: Update denote--retrieve-filename
From: |
ELPA Syncer |
Subject: |
[elpa] externals/denote 0ac3680b15 1/5: Update denote--retrieve-filename-title: remove dashes and capitalize |
Date: |
Mon, 15 Aug 2022 06:57:29 -0400 (EDT) |
branch: externals/denote
commit 0ac3680b15eaa9c00d92040cc918844a47c77b42
Author: Peter Prevos <peter@prevos.net>
Commit: Peter Prevos <peter@prevos.net>
Update denote--retrieve-filename-title: remove dashes and capitalize
---
denote.el | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/denote.el b/denote.el
index 08af56fe37..d5520fd383 100644
--- a/denote.el
+++ b/denote.el
@@ -795,9 +795,10 @@ contain the newline."
"Extract title from FILE name, else return `file-name-base'"
(if (and (file-exists-p file)
(denote--file-has-identifier-p file))
- (progn
- (string-match denote--title-regexp file)
- (match-string 1 file))
+ (let ((file-title (progn
+ (string-match denote--title-regexp file)
+ (match-string 1 file))))
+ (capitalize (replace-regexp-in-string "-" " " file-title)))
(file-name-base file)))
(defun denote--retrieve-title-value (file file-type)