branch: externals/denote commit 6dbea94b235c255e1f5113a32c9b93f34d73f2db Author: Protesilaos Stavrou <i...@protesilaos.com> Commit: Protesilaos Stavrou <i...@protesilaos.com>
Set denote-link-use-org-id to nil (undo 2193501) A non-nil value requires extra setup and comes with potential downsides. We need to account for them and provide solutions where appropriate. Read issue 29 on the GitHub mirror: <https://github.com/protesilaos/denote/issues/29>. --- README.org | 26 ++++++++++++++------------ denote-link.el | 10 ++++++---- 2 files changed, 20 insertions(+), 16 deletions(-) diff --git a/README.org b/README.org index 2a817aec18..4c2cff5681 100644 --- a/README.org +++ b/README.org @@ -647,17 +647,19 @@ When ~denote-link~ is called with a prefix argument (=C-u= by default) it formats links like =[[denote:IDENTIFIER]]=. The user might prefer its simplicity. -[ Default value of ~denote-link-use-org-id~ changed as part of - {{{development-version}}} ] - #+vindex: denote-link-use-org-id When the user option ~denote-link-use-org-id~ is set to non-nil (the -default), inserted links in Org notes that target other Org notes will -use the standard =id:= type so the format is =[[id:IDENTIFIER][TITLE]]= -(the title is omitted is ~denote-link~ is called with a prefix argument, -as explained above). When, however, an Org note links to a note in -another file, the link with use our own =denote:= type as there is no -standard for this case. +default is nil), inserted links in Org notes that target other Org notes +will use the standard =id:= hyperlink type. The format is +=[[id:IDENTIFIER][TITLE]]= (the title is omitted if ~denote-link~ is +called with a prefix argument, as explained above). When, however, an +Org note links to a note of another file type (e.g Org to Markdown), the +link will use our own =denote:= type as there is no standard for this +case. + +# TODO 2022-07-03: Document potential downsides of the 'id:' type and +# write documentation on what the user must do to ensure that everything +# works properly. Inserted links are automatically buttonized and remain active for as long as the buffer is available. In Org this is handled automatically @@ -1466,9 +1468,9 @@ Everything is in place to set up the package. (require 'denote-retrieve) (require 'denote-link) -;; If you want links to and from Org notes to use the standard 'id:' -;; link type instead of 'denote:'. -(setq denote-link-use-org-id t) +;; Set to non-nil if you want links to and from Org notes to use the +;; standard 'id:' link type instead of 'denote:'. +(setq denote-link-use-org-id nil) ;; By default, we fontify backlinks in their bespoke buffer. (setq denote-link-fontify-backlinks t) diff --git a/denote-link.el b/denote-link.el index 5de8dabc60..6e7874acb0 100644 --- a/denote-link.el +++ b/denote-link.el @@ -200,7 +200,9 @@ and/or the documentation string of `display-buffer'." alist) :group 'denote-link) -(defcustom denote-link-use-org-id t +;; TODO 2022-07-03: After "ecosystem" elaborate on the responsibility +;; the user has to ensure things continue to work. +(defcustom denote-link-use-org-id nil "When non-nil use the ID link type in Org files, if appropriate. Newly created links from Org notes which target other Org notes @@ -211,9 +213,9 @@ will use the standard `id:' hyperlink type instead of the custom In practical terms, the ID ensures maximum compatibility with other tools in the Org ecosystem. -When the value is nil, Denote links rely on the custom `denote:' -hyperlink type (which should behave the same as the standard -`file:' link). +When the value is nil (the default), Denote links rely on the +custom `denote:' hyperlink type (which should behave the same as +the standard `file:' link). Other file types beside Org always use the `denote:' links." :type 'boolean