emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[BUG] org-store-link on document title


From: Anthony Carrico
Subject: [BUG] org-store-link on document title
Date: Wed, 28 Jun 2023 15:31:20 -0400
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.12.0

On 6/28/23 12:48, Ihor Radchenko wrote:
> I cannot reproduce.
> Please provide more details and report this under a different email
> subject, so that we can easily distinguish the two bugs.
> See https://orgmode.org/manual/Feedback.html#Feedback

Ah, very sorry for the distraction on the "This link has already been stored" issue.

I'll describe the behavior I observe, and a more useful behavior. I'm not sure this constitutes an actual bug, since org-store-link isn't documented to work on the title line of a document.

Org mode version 9.5.5 (release_9.5.5 @ /usr/share/emacs/28.2/lisp/org/)
GNU Emacs 28.2 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.36, cairo version 1.17.6) of 2023-01-02

To duplicate:

Create file test.org as in this example:
#+begin_example
#+TITLE: test org title link
#+end_example

1. go to title line of test.org, and do org-store link: 'C-c l'
2. go to new file test2.org, and do org-insert-link: 'C-c C-l M-p <RET>'

Here is the actual file test2.org produced by this method:
#+begin_example
[[file:test.org::+TITLE: test org title link]]
#+end_example

This isn't great because there is no description.

1. Expected file test2.org:
#+begin_example
[[file:test.org::+TITLE: test org title link][test org title link]]
#+end_example

Or even better:

2. Desired file test2.org:
#+begin_example
[[file:test.org][test org title link]]
#+end_example

Here the title is used as the description, and the file itself is linked, rather than the title line.

The second option makes more sense to me. Why? Because at the title line I intend to store a link to the document labeled with the title, and at a headline I intend to store a link to a section of the document labeled with the headline.

This option also produces cleaner html output (at least a few years ago--see org mailing list around 2020-08-06 with subject "ISSUE: Unable to resolve link (html export)").

--
Anthony Carrico



reply via email to

[Prev in Thread] Current Thread [Next in Thread]