<<ThisIsATarget>>
Links in org mode are a nested set of square brackets
[[ Reference ][ Description ]]
Pressing enter on a link in sublime will try to follow the link. If the link is a web reference org will try to open a web browser.
The link system I am using is based on the original orgmode for sublime text and is fairly extensible. Custom handlers can be built to allow you to link easily to your own services.
There are several special ways of locating within a file within a reference.
[[<PROTOCOL>:<FILENAME>::<LOCATOR>][<NAME>]]
To manually specify locators using special symbols:
- Custom Id
- #<IDNAME>
- Header
- *<HEADING TEXT>
- Row Col
- Row::Col
If your locator is only text and non numerical there is an order to how the text is matched:
- Target
- Custom Id
- Header
Targets are like anchors in an html file. A target is specified using double angle brackets.
<<TEXT>>
Org supports the ability to show images inline in the document These are done with Sublimes phantom support under an image link and do not count as lines of text. Org can download links off the web that reference images into a cache and display them locally. This can lock up sublime while the images are downloaded so turn on visualization with care.
- OrgShowAllImages - Shows all image links in the document
- OrgHideAllImages - Hides all image links in the document
- OrgShowImage - Shows a single image link in the document
- OrgHideImage - Hides a single image link in the document
NOTE: You can ask that sublime visualize images by default in a file using a startup comment:
#+STARTUP: inlineimages
A link can be more than just the filename. You can link to a specific line number like so:
[[file:links.org::3][File and Line Number Example]]
You can link to a heading using a star.
[[file:./links.org::*Images][Images Example]]
You can link without the star but it can match other things.
[[file:./links.org::Images][Images Example]]
Org has the concept of custom IDs. These are defined as a CUSTOM_ID property in a property drawer. To link to a heading with one of these IDs:
[[file:./links.org::#a-custom-id][Custom Id Example]]
OrgExtended has a couple of ways that it tries to help with authoring links.
The “Org Link To File” command lets you quickly create links between your org files. This is a powerful and quick way to create links between files.
The system will, by default, place the #+TITLE: comment as the desciption field of the link if present.
The autocompletion system knows about your orgDirs and org files. When you start typing a link the autocompletion system will kick in and will try to suggest files as you type the name of the file.
Selecting a header and using the “Org Create Link” command will create a link on your clipboard that you can paste somewhere else.
It will take into account custom IDs if present.
OrgExtended has a snippet for creating links:
<l
So you know you have a link to someplace somewhere and you don’t quite remember where the link was. OrgExtended can help with quick search through all your links across all files.
"Org Search Links"
Org Roam is an amazing package that works in conjunction with org mode. We do not have nearly the same functionality of that package, but we are slowly working in that direction. Org Roam supports the concept of back links. This is a display of the links that reference the current view rather than the links the current view references.
TODO: Describe how to do this.