Some ideas we discussed today, recording here for future reference:
#+vindex: hyperdrive-persist-location
- ~hyperdrive-persist-location~ :: Location where ~persist~ will store
data, currently ~hyperdrive-hyperdrives~ and ~hyperdrive-version-ranges~.
By default, uses the default ~persist~ location.
I'll need to also merge the info manual descriptions into the docstrings.
Consider automating the generation of function/command/variable documentation directly from their docstrings.
That might not be possible because the convention is to use the imperative mood in docstrings, while info manuals it is not. We seem to be following the respective conventions in both places already.
The extensions to
ox-texinfo.el
, which produce the above texi output, have been merged into org, and are documented in its manual. If you want to look at more examples, I suggest the transient manual.However we don't use commands such as
@defopt
and@deffn
, and we use free form lists to list key bindings.Here is a short excerpt from magit's info manual, that shows what a key binding and an option is supposed to look like, when (more or less) following the conventions:
‘U’ (‘magit-unstage-all’) Remove all changes from the staging area. -- User Option: magit-unstage-committed This option controls whether ‘magit-unstage’ "unstages" committed changes by reversing them in the index but not the working tree. The alternative is to raise an error.
Writing even such simple definitions in texinfo is IMO unbearable:
@table @asis [...] @item @kbd{U} (@code{magit-unstage-all}) @kindex U @findex magit-unstage-all Remove all changes from the staging area. @end table @defopt magit-unstage-committed This option controls whether @code{magit-unstage} "unstages" committed changes by reversing them in the index but not the working tree. The alternative is to raise an error. @end defopt
which is why I use org instead. But writing it using the same constructs that are being used for org's own manual itself, is not much better.
So I have written an extension to ox-texinfo that accept some special formatting that looks very close to the eventual output in the info file, instead of like the intermediate mess in the texi file. The org source for the above info output is just this:
- Key: U (magit-unstage-all) :: Remove all changes from the staging area. - User Option: magit-unstage-committed :: This option controls whether ~magit-unstage~ "unstages" committed changes by reversing them in the index but not the working tree. The alternative is to raise an error.
This obviates the need to manually insert
#vindex: foobar
all over the place! Thank you!!
By the way, the mentioned "extension to ox-texinfo" has been merged into Org a few releases ago.
Implemented in 056cf071. Thank you!!
Also 195a1a01 and 28c81e2d