descriptionPlugin for the Howl editor
ownerrepo.or.cz@soba23.anonaddy.me
last changeSun, 17 Mar 2024 14:31:33 +0000 (17 22:31 +0800)
content tags
add:
README.md

howl-parkour is a structured editing plugin for the Howl editor, based on the parkour library.

Configuration

In ~/.howl/init.lua or ~/.howl/init.moon:

howl.config.auto_square_brackets = true
howl.config.lispwords.scheme.lambda = 0
howl.config.repl_fifo = os.getenv('HOME')..'/.repl_fifo'
howl.config.emacs = true

These options can also be set interactively via the :set command (except lispwords).

auto_square_brackets

Rewrites any delimiter to a square bracket at certain locations.
Has effect only on Scheme; for Clojure and Fennel this behaviour is always on.
Works both when inserting and wrapping.
The locations are not configurable ATM, but are grouped by language in the code - see, for example, the Fennel config.

lispwords.dialect.word

The plugin comes with a set of indentation rules for each supported file type, but they are incomplete and sometimes will be wrong (due to multiple possible dialects under a single file type).
The lispwords table allows customizing those rules by setting the desired number of distinguished arguments a function/macro has. (0 is like defun in Emacs.)
As an example, see the built-in indent numbers for Scheme.

repl_fifo

This option can be set to the path of a named pipe from which a REPL (or anything, really) can read input.
Inserting a newline at the end of the last line of a paragraph will send the paragraph to this pipe.
Since REPL commands fit the criteria for paragraph (a top-level S-expression), they get sent as well.

emacs

The plugin comes with two key themes - emacs and CUA.
CUA is always enabled.
Setting this option to true will enable the emacs key theme, too. (A few CUA and built-in key bindings will be overriden.)

Note: The linked key themes are the only "documentation" on the available keyboard shortcuts ATM.

Bugs

Howl has character-oriented buffer API, but Parkour works with byte offsets.
In files with multibyte characters, word boundaries will not be where the plugin expects them to be, and various issues will occur.
There's some WIP in the multibyte branch on fixing this.

shortlog
2024-03-17 Georgi Kirilovlink to fmt configuration as examplemaster
2024-03-17 Georgi Kirilovsplit emacs key theme into section and reorder
2024-03-17 Georgi Kirilovadd backward-kill-sentence and fix the mapping
2024-03-17 Georgi Kirilovadd convolute-sexp
2024-03-17 Georgi Kirilovcatch up to the anylist/quasilist change
2024-03-17 Georgi KirilovMerge commit 'f9cb63561b743176ef831298a84c421fdb112f16'
2024-03-17 Georgi Kirilovadd copyright notice
2024-03-17 Georgi Kirilovadd copyright notice
2024-03-14 Georgi Kirilovpoint out that the keytheme files are worth reading
2023-08-27 Georgi Kirilovmention multibyte issues
2023-08-27 Georgi Kirilovuse range for alt+; consistent with the other wrappers
2023-08-27 Georgi Kirilovkeyboard layout independent bindings
2023-08-27 Georgi Kirilovremove QWERTY-specific "optimizations"
2023-08-27 Georgi Kirilovdo not reindent on pasting empty clipboard
2023-08-27 Georgi Kirilovproper clipboard handling
2023-08-27 Georgi Kirilovfix crash on setting howl.config.emacs
...
heads
5 weeks ago multibyte
5 weeks ago master