This "hidden option" lets the user do something like this (I prepend >
to escape the #):
> (setq denote-org-front-matter
> ":PROPERTIES:
> :ID: %4$s
> :END:
> #+title: %1$s
> #+date: %2$s
> #+filetags: %3$s
> #+identifier: %4$s
> \n")
Ultimately though, it gives us more flexibility if we ever want to
support extra features.
One such feature is the ability to create links using the org-id.el
library. See issue 8 over at the GitHub mirror, with feedback from
Kaushal Modi: <https://github.com/protesilaos/denote/issues/8>.
By removing the double hyphens, we indicate that these variables can be
relied upon by the user. In other words: these are hidden customisation
options for those who want to maintain some Do-It-Yourself code.
This makes it specific that the front matter is YAML-compliant. It also
gives us the option to support TOML.
Thanks to Kaushal Modi for the feedback in issue 4 over at the GitHub
mirror: <https://github.com/protesilaos/denote/issues/4>.
Putting the tags/keywords at the end of the file has several advantages:
1. It is consistent with how such interfaces are designed, such as with
the 'elfeed', 'notmuch', and 'mu4e' Emacs packages.
2. It makes it easier to read the title of the file even if it is
truncated.
3. Makes fontification look better, as the more intensely coloured
keywords are further apart from the date/identifier which is also
colourful.
One way to update existing file names in Dired:
* Switch to wdired (C-x C-q by default)
* M-x isearch-forward-regexp (bound to C-M-s by default)
* Search for (without the quotes) '--\(.*?\)--\(.*?\)\.org'
* While in isearch, type M-%
* For the replacement use (without the quotes) '--\2--\1.org'
* Verify the conversion as you go through the query-replace.
A similar series of steps can be followed for file contents (e.g. by
making the grep buffer editable with the wgrep package).
Before it was like 20220531_091625, but now it is 20220531T091625.
I also introduced a new face, in case someone wants to style the time
part separately.
It is not necessary to pollute the front matter with such details.
Files are always relative to the present directory. The linking
facility is updated to work as intended (per commit 929157d).
This is an update on commit cfe6e98, which was reverted earlier by
8167d0c.
This reverts commit cfe6e98e7b.
We actually need it for making links. Perhaps we can find a way to only
rely on the identifier. Will need to check this further.
Links will now always be relative to the current directory and use the
standard "file:" prefix.
This means that other packages, like org-transclusion, will work with
our notes without further tweaks.
Jack's contribution is below the ~15 line threshold that is required for
projects that are distributed via GNU ELPA (denote will be one of them
in the near future).
Contributions exceeding that limit require that the author assigns
copyright to the Free Software Foundation.