[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/denote adf8c6fdc8 02/33: Update denote-create-* command
From: |
ELPA Syncer |
Subject: |
[elpa] externals/denote adf8c6fdc8 02/33: Update denote-create-* commands to respect `denote-prompts` |
Date: |
Wed, 14 Feb 2024 06:57:46 -0500 (EST) |
branch: externals/denote
commit adf8c6fdc8d49b0c5957d949f14a7a3f504d1c46
Author: Vedang Manerikar <ved.manerikar@gmail.com>
Commit: Vedang Manerikar <ved.manerikar@gmail.com>
Update denote-create-* commands to respect `denote-prompts`
This commit modifies the following functions:
- `denote-type`
- `denote-date`
- `denote-subdirectory`
- `denote-template`
- `denote-signature`
Instead of overwriting the value of `denote-prompts`, this change adds
the specific symbol to the existing value of `denote-prompts`.
---
denote.el | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
diff --git a/denote.el b/denote.el
index c3e5cb52ca..2d1d505184 100644
--- a/denote.el
+++ b/denote.el
@@ -2249,6 +2249,10 @@ With optional PROMPT-TEXT use it instead of a generic
prompt."
(defalias 'denote-create-note 'denote
"Alias for `denote' command.")
+(defun denote--add-prompts (additional-prompts)
+ "Add all the elements in the ADDITIONAL-PROMPTS list to `denote-prompts'."
+ (seq-union denote-prompts additional-prompts))
+
;;;###autoload
(defun denote-type ()
"Create note while prompting for a file type.
@@ -2257,7 +2261,7 @@ This is the equivalent to calling `denote' when
`denote-prompts'
is set to \\='(file-type title keywords)."
(declare (interactive-only t))
(interactive)
- (let ((denote-prompts '(file-type title keywords)))
+ (let ((denote-prompts (denote--add-prompts '(file-type))))
(call-interactively #'denote)))
(defalias 'denote-create-note-using-type 'denote-type
@@ -2276,7 +2280,7 @@ This is the equivalent to calling `denote' when
`denote-prompts'
is set to \\='(date title keywords)."
(declare (interactive-only t))
(interactive)
- (let ((denote-prompts '(date title keywords)))
+ (let ((denote-prompts (denote--add-prompts '(date))))
(call-interactively #'denote)))
(defalias 'denote-create-note-using-date 'denote-date
@@ -2293,7 +2297,7 @@ This is equivalent to calling `denote' when
`denote-prompts' is
set to \\='(subdirectory title keywords)."
(declare (interactive-only t))
(interactive)
- (let ((denote-prompts '(subdirectory title keywords)))
+ (let ((denote-prompts (denote--add-prompts '(subdirectory))))
(call-interactively #'denote)))
(defalias 'denote-create-note-in-subdirectory 'denote-subdirectory
@@ -2311,7 +2315,7 @@ This is equivalent to calling `denote' when
`denote-prompts' is
set to \\='(template title keywords)."
(declare (interactive-only t))
(interactive)
- (let ((denote-prompts '(template title keywords)))
+ (let ((denote-prompts (denote--add-prompts '(template))))
(call-interactively #'denote)))
(defalias 'denote-create-note-with-template 'denote-template
@@ -2325,7 +2329,7 @@ This is the equivalent to calling `denote' when
`denote-prompts'
is set to \\='(signature title keywords)."
(declare (interactive-only t))
(interactive)
- (let ((denote-prompts '(signature title keywords)))
+ (let ((denote-prompts (denote--add-prompts '(signature))))
(call-interactively #'denote)))
(defalias 'denote-create-note-using-signature 'denote-signature
- [elpa] externals/denote b02bf9d7c2 09/33: Add TODO about possible tweak to denote-rename-file, (continued)
- [elpa] externals/denote b02bf9d7c2 09/33: Add TODO about possible tweak to denote-rename-file, ELPA Syncer, 2024/02/14
- [elpa] externals/denote 764125525e 12/33: Broaden the scope of denote-rename-no-confirm to save buffers as well, ELPA Syncer, 2024/02/14
- [elpa] externals/denote 357c363242 17/33: Clarify that absent denote-prompts mean nil for relevant denote-rename-file arguments, ELPA Syncer, 2024/02/14
- [elpa] externals/denote ce9e2dd1bf 13/33: Complete the documentation of denote-rename-file, noting all modalities of interaction, ELPA Syncer, 2024/02/14
- [elpa] externals/denote ab20f4b0af 15/33: Make denote-dired-rename-files honour the denote-prompts (same as denote-rename-file), ELPA Syncer, 2024/02/14
- [elpa] externals/denote 37508c99d4 16/33: Update the documentation of denote-dired-rename-marked-files, ELPA Syncer, 2024/02/14
- [elpa] externals/denote 4cce51a092 22/33: Change how denote-rename-file passes DATE to denote-create-unique-file-identifier (per e9e9c8e), ELPA Syncer, 2024/02/14
- [elpa] externals/denote c5f8ef1d8a 23/33: Add TODO about possible tweak to denote-rename-file, ELPA Syncer, 2024/02/14
- [elpa] externals/denote 8faf120dff 26/33: Broaden the scope of denote-rename-no-confirm to save buffers as well, ELPA Syncer, 2024/02/14
- [elpa] externals/denote 77eafb2dfe 25/33: Start updating the manual for denote-rename-file (WORK-IN-PROGRESS), ELPA Syncer, 2024/02/14
- [elpa] externals/denote adf8c6fdc8 02/33: Update denote-create-* commands to respect `denote-prompts`,
ELPA Syncer <=
- [elpa] externals/denote ad13d32348 31/33: Clarify that absent denote-prompts mean nil for relevant denote-rename-file arguments, ELPA Syncer, 2024/02/14
- [elpa] externals/denote 1cdb49e227 32/33: Merge branch 'rename-honours-denote-prompts' of github.com:protesilaos/denote into rename-honours-denote-prompts, ELPA Syncer, 2024/02/14
- [elpa] externals/denote ab04f5b774 04/33: Fix typo in variable name in documentation, ELPA Syncer, 2024/02/14
- [elpa] externals/denote 60cf6b6125 05/33: Acknowledge maxbrieiev for commit 7d18b7b, ELPA Syncer, 2024/02/14
- [elpa] externals/denote 16b48265e2 08/33: Change how denote-rename-file passes DATE to denote-create-unique-file-identifier (per e9e9c8e), ELPA Syncer, 2024/02/14
- [elpa] externals/denote 5d4c78361a 10/33: Fix typo in denote-rename-file doc string, ELPA Syncer, 2024/02/14
- [elpa] externals/denote 6e050e4268 11/33: Start updating the manual for denote-rename-file (WORK-IN-PROGRESS), ELPA Syncer, 2024/02/14
- [elpa] externals/denote 6179fb7541 14/33: Ensure double spacing in a sentence of denote-rename-file docstring, ELPA Syncer, 2024/02/14
- [elpa] externals/denote 8e18c5664d 18/33: Add WORK-IN-PROGRESS implementation of 'denote-rename-file' that honours 'denote-prompts', ELPA Syncer, 2024/02/14
- [elpa] externals/denote 96d432f746 19/33: Update denote-create-* commands to respect `denote-prompts`, ELPA Syncer, 2024/02/14