Skip to content

Releases: getreu/tp-note

1.23.2

16 Nov 09:43
Compare
Choose a tag to compare
New option `--config-defaults` / Viewer: serve links with URL fragments

From version v1.23 on, Tp-Note merges configuration files into its internal
configuration. Consequently, without custom changes no configuration file
is required at all. Nevertheless, to get a copy from the internal configuration
(you can base your custom configuration file upon) a `--config-defaults` option
is added.

Another improvement concerns the viewer's link rewriting code: with this release
URL fragments (starting with `#`) are rendered correctly. This allows you for
example to add a hyperlinked table of contents at the beginning of your notes.
Also footnotes like `[^1]` are rendered correctly.

v1.23.1

13 Nov 08:08
Compare
Choose a tag to compare
Maintenance release

This reverts the commit `72bc7f2` that had been mistakenly merged into master.

    72bc7f2 Rename the root path marker file to `tpnote.toml`

It restores the original name of the marker file: `.tpnote.toml`

v1.23.0

12 Nov 18:46
Compare
Choose a tag to compare
Merge config files / Zettelkasten support

Tp-Note is shipped with a default internal configuration that can be customized
by merging a series of configuration files from various locations into the
default values. This happens in the following order:

1. Unix and MacOS only: '`/etc/tpnote/tpnote.toml`'
2. The file where the environment variable '`TPNOTE_CONFIG`' points to.
3. The user's configuration file:
   - Unix: '`~/.config/tpnote/tpnote.toml`'
   - Windows: '`C:\Users\<LOGIN>\AppData\Roaming\tpnote\config\tpnote.toml>`'
   - MacOS: '`/Users/<LOGIN>/Library/Application Support/tpnote`'
4. At startup all parent directories of the note file path '`<PATH>`'are
   searched for a marker file named '`tpnote.toml`'. If found, the document root
   moves from '`/`' the found location. If present and its content is not empty,
   Tp-Note interprets the file's content as configuration file.
5. The file indicated by the command line parameter '`--config <FIlE>`'.

When Tp-Note starts, it first merges all available configuration files into
the default configuration. Then the resulting syntax is checked.  If not
correct, the last sourced configuration file is renamed (thus disabled) and
Tp-Note starts with its internal default configuration. For debugging, you can
print out the merge result with '`-V -b -d trace`'.

To write a custom configuration file, first start with a complete default
configuration you can generate by invoking Tp-Note with '`-V -b -c`'
(no '`-d`').

```sh
tpnote -V -b -c ~/.config/tpnote/tpnote.toml
```

Some filename and template related variables are grouped into a '`scheme`'.
The shipped configuration file lists two schemes: '`default`' and '`zettel`'.
The scheme used when creating a new note, is selected by the commend line
option '`--scheme`', the environment variable '`TPNOTE_SCHEME`' or the
configuration variable '`arg_default.scheme`'. The scheme selected when
synchronizing a Tp-Note header with its filename depends on the
value of the header variable '`scheme:`' which defaults to '`default`'
(cf. '`scheme_sync_default`').

v1.22.13

08 Nov 13:51
Compare
Choose a tag to compare
Viewer bugfix: store the path to non-base-documents

This fixes a regression introduced with

    d1c0ed4 2023-10-31
    Error when `fm_sort_tag` is sequential and duplicate

in Tp-Note version v1.22.11

v1.22.9

19 Oct 17:16
Compare
Choose a tag to compare
Minor improvements in Markdown parsing

The version now recognizes all the official Markdown escape `\`
characters when searching for Hyperlinks or rendering `.txtnote` files.

See
[CommonMark Spec](https://spec.commonmark.org/0.30/#backslash-escapes)
for more details.

v1.22.8

18 Oct 12:17
Compare
Choose a tag to compare
Viewer renderer: resolve shorthand links to their link text

* Viewer: When viewing documents, shortcut links are resolved to their title.
  For example: a shorthand link `tpnote:docs/20230513` that targets the file
  `docs/20230513-Animals.md` is shown as a hyperlink with the link text
  "Animals" in the browser.

* Viewer: hyperlinks with embedded images are now supported.

* The `.txtnote` renderer now parses inline images and hyperlinks with inline
  images.

v1.22.7

14 Oct 14:30
Compare
Choose a tag to compare
Viewer: link to other docs with shorthand links, minor regr. fixes

New features:

* A shorthand link in a Tp-Note document e.g. `[text](tpnote:123)` is now
  expanded when being viewed. The renderer searches for a file starting
  with the sort-tag `123` on disk and displays the filename (without sort-tag).
  For example: a shorthand link to the file `123-My Animals.md` can be
  written as`<tpnote:123>` and the link will be displayed as `My Animals`.
* HTML rendition: The erroneous link path is now shown next to the error
  message.

(Minor) bug fixes:

* `file_ext: ''` is allowed again (regression introduced in v1.22.0)
* The viewer opens also (with an error message) in case of syntax errors
  in `file_ext:` or `sort_tag:`. These syntax errors had been mistakenly
  considered being fatal since v1.22.0.

Internal improvements:

* The link rewriting code is heavily refactored, simplified and easier to
  maintain.

v1.22.6

10 Oct 16:10
Compare
Choose a tag to compare
New shortcut notation to link Tp-Note documents

* Links in Tp-Note documents: Add new optional scheme `tpnote:` for local links,
  e.g. in Markdown the autolink `<tpnote:dir/my%20other%20doc.md>` targets
  `dir/my other doc.md`. The link is displayed as `my other doc`.
* Configuration: the variable `filename.extensions` groups all former
  `filename.extensions_*` variables (config breaking change).
* Viewer: internal improvements handling HTML escape codes and percent codes
  in URLs.
* Integration: register additional Tp-Note files extension: `.txtnote`. The
  viewer only links, no markup.
* Template: new filter: `link_text_picky`, similar to `link_text`. The latter
  always return the fist link found, `link_text_picky` rejects obvious
  meaningless link text content.

v1.22.5

01 Oct 10:25
Compare
Choose a tag to compare
Improve `.txtnote` renderer: recognize Markdown autolink

`.txtnote` renderer: Recognize Markdown autolinks, e.g. <https:getreu.net> or <[email protected]>

Breaking configuration change:

* Rename `tmpl_html.linux.*` variables to `tmpl_html.unix.*`

v1.22.4

29 Sep 18:37
Compare
Choose a tag to compare
Add compilation target `freebsd`, fixes #17