- link via CUSTOM_ID
- CUSTOM_ID is added to heading using
C-c C-x p
(org-set-property
)
- CUSTOM_ID is added to heading using
- link via text search in headings
- Requires exact match to heading text
- Not recommended
- Very fragile against any change to the target heading
- link via autogenerated ID
- ID is generated by calling
M-x org-store-link
with point on the target heading. - This requires that the variable
org-id-link-to-org-use-id
is not nil.- There are various possible values for this variable.
- I have it set to
create-if-interactive-and-no-custom-id
.
- ID is generated by calling
- link via explicit target
- Requires exact match to text of target
- link via cheating
- This only works in
org-ruby
, but not in org itself - We use an anchor that is the headline text, but converted to lower case and with spaces converted to hyphens
- This only works in
- [X] Works
- [X] Works
- [X] Works
- [X] Works
- [ ] Fails because the target does not exist from the emacs point of view
Using C-c C-e h o
or similar
- [X] Works
- [ ] Broken in org 8.2.7 if the heading contains spaces (see this thread)
- [X] Works
- [ ] Also broken in 8.2.7
- [ ] Fails
- [ ] Broken because the CUSTOM_ID property does not get made into an anchor by org-ruby
- [ ] Broken because the link is transformed into a link to a file with the name of the heading
- [ ] Broken because no link is created at all
- [ ] Broken because the angle bracket notation for anchors is not recognised by org-ruby
- [X] Works because we have crafted the link to match the anchor syntax that org-ruby generates
Thanks, this was very informative. Do you plan on raising any of this as an issue against https://github.com/wallyqs/org-ruby ? Do you mind if I raise an issue and link to this?