[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[O] Agenda buffer and relative links
From: |
François Pinard |
Subject: |
[O] Agenda buffer and relative links |
Date: |
Thu, 05 Jan 2012 22:39:32 -0500 |
Hi again, Org people.
When Org mode defines a link for me, it sometimes changes it so it
becomes relative. If within the file ~/fp/notes/notes.org, I wanted to
create the link:
[[file:~/fp/notes/VCS/GitHub.org][GitHub]]
Org mode really creates:
[[file:VCS/GitHub.org][GitHub]]
I presume this is because of the location of "notes.org" rather than
because of the value of org-directory, which happens to be "~/fp/notes".
This is OK in general, but not always.
For example, doing "C-a a a" today, I get this line among others
(squeezed so it fits in this message):
notes: Scheduled: TODO *[[file:Informatique/Entretien.org][Entretien]]
and clicking on the displayed "Entretien" link yields a white window.
The problem is that the *Org Agenda* buffer is associated with the "~/"
directory, and the relativized name is then wrong.
Because all my agenda-files happen to be directly within org-directory,
a sufficient counter-measure is to have this line in my ~/.emacs file:
(add-hook 'org-agenda-mode-hook (lambda () (cd org-directory)))
While it solves my problem, I have feeling that there is something
deeper which might likely affect many Org mode users, and for which I
have no general solution to offer. In the worst scenario, the solution
might be to never relativize links, but maybe someone would have a
better idea about this. In any case, I decided to report it.
François
- [O] Agenda buffer and relative links,
François Pinard <=