Hey :))
Most of my setup is based on this very excellent guide on the subject (https://blog.trinket.icu/articles/writing-your-first-kakrc)
Some key features I'd like to single out:
For looks I have few important parts, but I do have:
add-highlighter global/ number-lines -hlcursor -relative -separator " " -cursor-separator " |"
add-highlighter global/ show-matching
set-option global ui_options terminal_assistant=none
For function, I have:
- Cycle trough auto-complete suggestions with tab is such a nice feature
# Cycle autocomplete with tab
hook global InsertCompletionShow .* %{
try %{
exec -draft 'h<a-K>\h<ret>'
map window insert <s-tab> <c-p>
map window insert <tab> <c-n>
}
}
hook global InsertCompletionHide .* %{
unmap window insert <tab> <c-n>
unmap window insert <s-tab> <c-p>
}
- Quickly move between open buffers by pressing space + b/n/m
## Buffer navigation
map -docstring "Close current buffer" global user b ": db<ret>"
map -docstring "goto previous buffer" global user n ": bp<ret>"
map -docstring "goto next buffer" global user m ": bn<ret>"
- Copy to and paste from system clipboard (this might need altering depending on which app you want to use for clipboards. I use xclip)
## Copy to and paste from system clipboard
map -docstring "Copy to system clipboard" global user y "<a-|> xclip -selection clipboard<ret>"
map -docstring "Paste from system clipboard" global user p "<a-!> xclip -o -selection clipboard<ret>"
- Comment and un-comment lines by pressing
## Comment lines
map global normal <c-v> ":comment-line<ret>"
- I really like the ability to quickly insert new-lines
## Insert newlines
map -docstring "Insert newline above" global user [ "O<esc>j"
map -docstring "Insert newline below" global user ] "o<esc>k"
I have some other stuff in my kakrc too, but that is for more specific use cases :))