[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/denote 2bc5df6011 103/355: denote-file-type: 'markdown-
From: |
ELPA Syncer |
Subject: |
[elpa] externals/denote 2bc5df6011 103/355: denote-file-type: 'markdown-yaml', not 'markdown' |
Date: |
Sun, 26 Jun 2022 23:58:06 -0400 (EDT) |
branch: externals/denote
commit 2bc5df6011b345cbe2e6c1024cc5ca5b0feca36a
Author: Protesilaos Stavrou <info@protesilaos.com>
Commit: Protesilaos Stavrou <info@protesilaos.com>
denote-file-type: 'markdown-yaml', not 'markdown'
This makes it specific that the front matter is YAML-compliant. It also
gives us the option to support TOML.
Thanks to Kaushal Modi for the feedback in issue 4 over at the GitHub
mirror: <https://github.com/protesilaos/denote/issues/4>.
---
README.org | 6 +++---
denote.el | 23 ++++++++++++-----------
2 files changed, 15 insertions(+), 14 deletions(-)
diff --git a/README.org b/README.org
index d89c6af2a3..e895d863e8 100644
--- a/README.org
+++ b/README.org
@@ -252,8 +252,8 @@ This is how it looks for Org mode (~denote-file-type~ is
nil):
#+identifier: 20220610T134640
#+end_example
-For Markdown, it looks like this (~denote-file-type~ has the =markdown=
-value):
+For Markdown, it looks like this (~denote-file-type~ has the
+=markdown-yaml= value):
#+begin_src emacs-lisp
---
@@ -511,7 +511,7 @@ Everything is in place to set up the package.
'("emacs" "philosophy" "politics" "economics"))
(setq denote-infer-keywords t)
(setq denote-sort-keywords t)
-(setq denote-file-type nil) ; default is Org mode, else set `markdown' or
`text'
+(setq denote-file-type nil) ; default is Org mode, else set `markdown-yaml' or
`text'
(setq denote-front-matter-date-format 'org-timestamp)
diff --git a/denote.el b/denote.el
index bdb23d64a2..f6ab12da7a 100644
--- a/denote.el
+++ b/denote.el
@@ -117,15 +117,16 @@ If nil, show the keywords in their given order."
By default (a nil value), the file type is that of Org mode.
-When the value is the symbol `markdown', the file type is that of
-Markdown mode.
+When the value is the symbol `markdown-yaml', the file type is
+that of Markdown mode and the front matter uses a YAML-compliant
+way to represent tags.
When the value is `text', the file type is that of Text mode.
Any other non-nil value is the same as the default."
:type '(choice
(const :tag "Org mode (default)" nil)
- (const :tag "Markdown" markdown)
+ (const :tag "Markdown" markdown-yml)
(const :tag "Plain text" text))
:group 'denote)
@@ -315,7 +316,7 @@ output is sorted with `string-lessp'."
(defun denote--file-extension ()
"Return file type extension based on `denote-file-type'."
(pcase denote-file-type
- ('markdown ".md")
+ ('markdown-yaml ".md")
('text ".txt")
(_ ".org")))
@@ -349,13 +350,13 @@ TITLE, DATE, KEYWORDS, FILENAME, ID are all strings which
are
provided by `denote-new-note'."
(let ((kw (denote--file-meta-keywords keywords)))
(pcase denote-file-type
- ('markdown (concat "---" "\n"
- "title: " title "\n"
- "date: " date "\n"
- "tags: " kw "\n"
- "identifier: " id "\n"
- "---" "\n"
- "\n"))
+ ('markdown-yaml (concat "---" "\n"
+ "title: " title "\n"
+ "date: " date "\n"
+ "tags: " kw "\n"
+ "identifier: " id "\n"
+ "---" "\n"
+ "\n"))
('text (concat "title: " title "\n"
"date: " date "\n"
- [elpa] externals/denote 0e65f05bbb 080/355: Use 'delete-region' instead of 'delete-line', (continued)
- [elpa] externals/denote 0e65f05bbb 080/355: Use 'delete-region' instead of 'delete-line', ELPA Syncer, 2022/06/27
- [elpa] externals/denote ab27f5a547 086/355: Tweak sample configuration, ELPA Syncer, 2022/06/27
- [elpa] externals/denote f97f1f8b56 082/355: chore: Ignore compiled and autoloads Emacs-Lisp files, ELPA Syncer, 2022/06/27
- [elpa] externals/denote 8167d0c30c 091/355: Revert "Stop recording the file path in the front matter", ELPA Syncer, 2022/06/27
- [elpa] externals/denote 6227df012f 100/355: Make org-capture always set .org extension, ELPA Syncer, 2022/06/27
- [elpa] externals/denote e840648623 098/355: Fix typo in the manual, ELPA Syncer, 2022/06/27
- [elpa] externals/denote 9f192263db 092/355: Remove file path from front matter; improve links, ELPA Syncer, 2022/06/27
- [elpa] externals/denote db9584f51d 093/355: BREAKING Change date/identifier pattern, ELPA Syncer, 2022/06/27
- [elpa] externals/denote 3e2b560548 099/355: Elaborate on the Overview of Denote, ELPA Syncer, 2022/06/27
- [elpa] externals/denote cfe6e98e7b 090/355: Stop recording the file path in the front matter, ELPA Syncer, 2022/06/27
- [elpa] externals/denote 2bc5df6011 103/355: denote-file-type: 'markdown-yaml', not 'markdown',
ELPA Syncer <=
- [elpa] externals/denote d83c166c0d 125/355: Fix regexp for keywords, ELPA Syncer, 2022/06/27
- [elpa] externals/denote ebdacb3fea 073/355: Update doc string of denote-directory function, ELPA Syncer, 2022/06/27
- [elpa] externals/denote 91f4780779 083/355: Merge pull request #3 from kaushalmodi/add-gitignore, ELPA Syncer, 2022/06/27
- [elpa] externals/denote 17ad20f356 097/355: Document section on front matter, ELPA Syncer, 2022/06/27
- [elpa] externals/denote 929157d424 089/355: Stop using link abbreviation, ELPA Syncer, 2022/06/27
- [elpa] externals/denote a809e9ea1d 087/355: Clarify active development; things might break, ELPA Syncer, 2022/06/27
- [elpa] externals/denote 3f9bfcb74e 101/355: Name the FSF as the copyright holder, ELPA Syncer, 2022/06/27
- [elpa] externals/denote 299b8970ee 095/355: Add support for notes in Markdown and Plain Text, ELPA Syncer, 2022/06/27
- [elpa] externals/denote 112a12e6e5 130/355: Remove duplicate word from face names, ELPA Syncer, 2022/06/27
- [elpa] externals/denote bca23b3e3d 115/355: Clarify how front matter variables are used, ELPA Syncer, 2022/06/27