[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/denote 2a5dfea29b 2/6: Rename denote-change-file-type t
From: |
ELPA Syncer |
Subject: |
[elpa] externals/denote 2a5dfea29b 2/6: Rename denote-change-file-type to avoid confusion |
Date: |
Thu, 19 Oct 2023 03:58:08 -0400 (EDT) |
branch: externals/denote
commit 2a5dfea29bba57f44f4a7c02b18615fbad69ada3
Author: Protesilaos Stavrou <info@protesilaos.com>
Commit: Protesilaos Stavrou <info@protesilaos.com>
Rename denote-change-file-type to avoid confusion
---
README.org | 18 +++++++++++-------
denote.el | 7 ++++++-
2 files changed, 17 insertions(+), 8 deletions(-)
diff --git a/README.org b/README.org
index b62b288752..f7794d3b0f 100644
--- a/README.org
+++ b/README.org
@@ -1265,19 +1265,23 @@ respective front matter.
:CUSTOM_ID: h:85b65995-89fd-4978-bba3-7bb6c8d6f945
:END:
-#+findex: denote-change-file-type
-The command ~denote-change-file-type~ provides the convenience of
-converting a note taken in one file type, say, =.txt= into another
-like =.org=. It presents a choice among the ~denote-file-type~
-options.
+[ The command is renamed from ~denote-change-file-type~ to
+ ~denote-change-file-type-and-front-matter~ as part of
{{{development-version}}}
+ because some users thought it was performing full text conversion. ]
+
+#+findex: denote-change-file-type-and-front-matter
+The command ~denote-change-file-type-and-front-matter~ provides the
+convenience of converting a note taken in one file type, say, =.txt=
+into another like =.org=. It presents a choice among the
+~denote-file-type~ options.
The conversion does NOT modify the existing front matter. Instead, it
prepends new front matter to the top of the file. We do this as a
safety precaution since the user can, in principle, add arbitrary
extras to their front matter that we would not want to touch.
-If in Dired, ~denote-change-file-type~ operates on the file at point,
-else it prompts with minibuffer completion for one.
+If in Dired, ~denote-change-file-type-and-front-matter~ operates on
+the file at point, else it prompts with minibuffer completion for one.
The title of the file is retrieved from a line starting with a title
field in the file's front matter, depending on the previous file type
diff --git a/denote.el b/denote.el
index 3d3bddf373..ae1edb157e 100644
--- a/denote.el
+++ b/denote.el
@@ -2349,8 +2349,13 @@ files)."
(denote-rewrite-front-matter new-name title keywords file-type)
(denote--add-front-matter new-name title keywords id file-type))))))
+(define-obsolete-function-alias
+ 'denote-change-file-type
+ 'denote-change-file-type-and-front-matter
+ "2.1.0")
+
;;;###autoload
-(defun denote-change-file-type (file new-file-type)
+(defun denote-change-file-type-and-front-matter (file new-file-type)
"Change file type of FILE and add an appropriate front matter.
If in Dired, consider FILE to be the one at point, else prompt
- [elpa] externals/denote updated (382cce8b9f -> baf79b494a), ELPA Syncer, 2023/10/19
- [elpa] externals/denote 2a5dfea29b 2/6: Rename denote-change-file-type to avoid confusion,
ELPA Syncer <=
- [elpa] externals/denote f7406ef475 1/6: Refine conditionality of denote--file-with-temp-buffer-1, ELPA Syncer, 2023/10/19
- [elpa] externals/denote 36ed254aa0 3/6: Clarify the doc string of denote-after-new-note-hook, ELPA Syncer, 2023/10/19
- [elpa] externals/denote baf79b494a 6/6: Update error message of denote-dired-rename-marked-files-using-front-matter, ELPA Syncer, 2023/10/19
- [elpa] externals/denote f9fe0c374c 5/6: Renaming with front matter no longer requires buffer save, ELPA Syncer, 2023/10/19
- [elpa] externals/denote c4bbd64e2a 4/6: Reposition denote-change-file-type-and-front-matter, ELPA Syncer, 2023/10/19