Convert "short" and "pretty" (and "default") formaters to plugins

further to https://github.com/jrnl-org/jrnl/pull/1177
This commit is contained in:
MinchinWeb 2021-05-09 16:29:21 -06:00
parent e1d2f873da
commit 1fd04ad03d
5 changed files with 85 additions and 30 deletions

View file

@ -146,6 +146,17 @@ Some implementation notes:
*jrnl* will call **export_entry()** on each entry in turn and then
concatenate the results together.
### Special Exporters
There are a few "special" exporters, in that they are called by *jrnl* in
situations other than a traditional export. They are:
- **short** -- called by `jrnl --short`. Displays each entry on a single line.
The default is to print the timestamp of the entry, followed by the title.
The built-in (default) plugin is at `jrnl.plugins.exporter.short`.
- **default** -- called when a different format is not specified. The built-in
(default) plugin is at `jrnl.plugins.exporter.pretty`.
## Development Tips
- editable installs (`pip install -e ...`) don't seem to play nice with