Great kakrc's (like Mawww's)

I don’t generally like to encourage any form of cargo culting – but there is a lot of great stuff in this kakrc. We can use this thread to pull out interesting stuff, if really interesting and stand alone put under Recipes.

1 Like

I am not certain exactly how the xml tag matching is supposed to function

1 Like

map global normal = ':prompt math: %{exec "a%val{text}<lt>esc>|bc<lt>ret>"}<ret>'

Today I learned about %val{text}.

define-command find -params 1 -shell-candidates %{ ag -g '' --ignore "$kak_opt_ignored_files" } %{ edit %arg{1} }

…OK, that’s pretty great. I’ll steal that right now (but of course I’ll use ripgrep instead of ag).

I like to browse other kakrcs, plenty of new things to learn (and steal :wink:) Recently I had found SolitudeSF’s config, and I was inspired to remap space to ,

1 Like

I know what these cases are – not sure I get the value of the defs?

1 Like

i added them just in case i need to convert something, but never actually had the need to use them. might as well delete them to keep config cleaner. is worth adding to the list – I might roll these up to the top level.

I like this one from @mawww:

define-command delete-buffers-matching -params 1 %{
  evaluate-commands -buffer * %{
    evaluate-commands %sh{ case "$kak_buffile" in $1) echo delete-buffer ;; esac }

single-process-pipe from @occivink is also interesting. With a few checks it could be quite robust.