Klog from the comfort of Emacs
  • Emacs Lisp 100%
Find a file
2026-03-25 23:45:58 -04:00
.gitignore chore: ignore autoloads and Eask 2026-01-24 20:13:11 -05:00
.mise.toml chore(mise): add Eask 2026-02-10 17:11:00 -05:00
Eask refactor(klog-mode)!: move under klog feature 2026-02-06 14:42:24 -05:00
klog-mode.el ; * klog-mode.el (klog-mode): Call correct function. 2026-03-12 10:05:49 -04:00
klog.el ; * klog.el (klog-mode-line-bookmark-determine-status): Update mode line. 2026-03-25 23:45:58 -04:00
README.org ; Switch to Org Mode README. 2026-03-09 12:37:54 -04:00

klog.el

Klog from the comfort of Emacs

Requirements

Installation

At the moment, klog.el is not on any package archive. (I have plans to add it after it has been used a bit more.) You can install it using package-vc-install or the use-package equivalent.

Usage

[!NOTE] klog.el depends on klog's bookmark system, so only bookmarked klog files will be recognized by klog.el.1

klog.el assumes that you do not multitask, so only one bookmark at a time can be active. To select a bookmark, use klog-select-bookmark. Once selected, use klog-start and klog-stop to add new entries under the current bookmark. You can switch activities using klog-switch.

If you want to edit the klog file directly, use klog-find-bookmark. You may find klog-mode helpful.

Major mode

klog.el comes with a major mode, klog-mode. klog-mode requires this Tree-sitter grammar. Add ("\\.klg\\'" . klog-mode) to auto-mode-alist. If you use use-package, then the following works:

(use-package klog-mode
  :mode "\\.klg\\'")

You may wish to change the amount of indentation. To do so, customize klog-indent-offset. Use customize-group klog to see a full list of customizations (faces etc.. If you want to modify fontification or indentation, occur defvar in klog-mode.el to see what you can modify.

I recommend enabling auto-revert-mode in klog buffers. You can add auto-revert-mode to klog-mode-hook to do so.

Outline

klog-mode works with outline.el so that you can hide/show a record. Simply enable outline-minor-mode in a klog-mode buffer or add outline-minor-mode to klog-mode-hook.

Extending

klog.el is designed to be extensible. Use klog-command or klog-bookmark-command to build custom functions. If you want to work only with a specific bookmark, wrap relevant forms within klog-with-bookmark.

Contributing

I am an amateur hobbyist lisper, and my code probably reflects that. If you have suggestions or bugfixes, please open an issue or a PR. Collaboration is always welcome!

Gratitude


1

I hope to integrate klog with project.el and friends eventually.