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

ta-parkour is a structured editing plugin for the Textadept editor, based on the parkour library.

Configuration

In ~/.textadept/init.lua:

local pk = require'ta-parkour'

-- optional:
pk.auto_square_brackets = true
pk.lispwords.scheme.lambda = 0
pk.repl_fifo = os.getenv('HOME')..'/.repl_fifo'
pk.emacs = true

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: menu mnemonics conflicting with Alt+ shortcuts of an active key theme will be disabled in the current buffer.
Note: The linked key themes are the only "documentation" on the available keyboard shortcuts ATM.

shortlog
2024-03-17 Georgi Kirilovmigrate to 12.0master
2024-03-17 Georgi Kirilovlink to fmt configuration as example
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 Kirilovreorder CUA mappings to match emacs
2024-03-14 Georgi Kirilovsplit the emacs key theme into sections
2024-03-14 Georgi Kirilovadd backward-kill-sentence and fix the mapping
2024-03-14 Georgi Kirilovadd convolute-sexp
2024-03-14 Georgi Kirilovsplit keythemes per UI
2024-03-14 Georgi Kirilovpoint out that the keytheme files are worth reading
2024-03-14 Georgi Kirilovcatch up to the anylist/quasilist change
2023-08-27 Georgi Kirilovremove QWERTY-specific "optimizations"
2023-08-27 Georgi Kirilovdrop the extra level of indirection
2023-08-27 Georgi Kirilovswap Linux/Win32 and Terminal keys
2023-08-27 Georgi Kirilovdon't rely on guesswork for binding the keys
...
heads
5 weeks ago master