The Kalem Book GitHub

This Book describes Kalem's main branch, which may be ahead of the latest release.

When something goes wrong

Kalem keeps a log, kalem.log, in its state directory: $KALEM_STATE_DIR when it is set, else kalem in $XDG_STATE_HOME, in %LOCALAPPDATA% on Windows, or in ~/.local/state. Each start begins a new log and keeps the two before it as kalem.log.1 and kalem.log.2, so the log of a session that went wrong is still there after a restart.

The setting log.level (error, warn, info, the default, debug or trace) says how much goes into the log. The environment variable KALEM_LOG overrides it for one run, per part of Kalem too: KALEM_LOG=debug kalem notes.org, or KALEM_LOG=kalem_core=debug,info for more detail from the core only.

When Kalem crashes, it writes the error with its backtrace into the log and a report beside it, crash-DATE.txt: the version, the platform, the settings files and their problems, and the error. Please attach the report and the log to a bug report, with the output of kalem tui --detect for problems in the terminal.