AutoYADM commit: 2025-07-08 17:40:19
This commit is contained in:
parent
6bbf9dfe6e
commit
62e9b93736
4 changed files with 92 additions and 96 deletions
|
@ -1,3 +1,4 @@
|
|||
provide-module colemak %~
|
||||
# Colemak-friendly bindings
|
||||
|
||||
map global normal m "h"
|
||||
|
@ -117,3 +118,4 @@ map global normal <a-c-s-l> "<a-c-s-e>"
|
|||
# map global normal <a-c-c-b> "<a-c-c-q>"
|
||||
# map global normal <a-c-c-q> "<a-c-c-b>"
|
||||
|
||||
~
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
provide-module lsp %∴
|
||||
# load plugin
|
||||
eval %sh{kak-lsp}
|
||||
|
||||
|
@ -371,3 +372,4 @@ hook -group lsp-filetype-sh global BufSetOption filetype=sh %{
|
|||
}
|
||||
}
|
||||
|
||||
∴
|
||||
|
|
86
.config/kak/extra.kak
Normal file
86
.config/kak/extra.kak
Normal file
|
@ -0,0 +1,86 @@
|
|||
# loading extra configuration that requires dependencies,
|
||||
# not suitable for remote servers and whatnot
|
||||
|
||||
evaluate-commands %sh{ kak-tree-sitter -dks --init $kak_session }
|
||||
evaluate-commands %sh{kak-popup init}
|
||||
# evaluate-commands %sh{ reflow init }
|
||||
# set-option global reflow_command %{
|
||||
# cat > "${input=$(mktemp)}"
|
||||
# # reflow --width "$kak_opt_reflow_width" --tabstop "$kak_opt_tabstop" < "$input" || cat "$input"
|
||||
# fmt -u < "$input" | perl -CS -pe 's/([.!?])\s{2,}/\1 /g' || cat "$input"
|
||||
# rm -f "$input"
|
||||
# }
|
||||
|
||||
require-module spell
|
||||
require-module lsp
|
||||
require-module hop-kak
|
||||
require-module fishr
|
||||
require-module title-bar
|
||||
require-module notes
|
||||
require-module plugins
|
||||
require-module yazi
|
||||
require-module luar
|
||||
require-module clipboard
|
||||
set-option global luar_interpreter luajit
|
||||
# only set to foot if we are on wayland
|
||||
hook global ModuleLoaded wayland %{
|
||||
set-option global termcmd 'footclient dash -c'
|
||||
}
|
||||
# needed for tree-sitter to respect show-matching
|
||||
define-command -override tree-sitter-user-after-highlighter %{
|
||||
add-highlighter -override buffer/show-matching show-matching
|
||||
}
|
||||
|
||||
# manually requiring needed for some reason 😢
|
||||
# require-module peneira
|
||||
|
||||
# declare-user-mode peneira
|
||||
# map -docstring %{
|
||||
# Picker mode
|
||||
# } global user f ': enter-user-mode peneira<ret>'
|
||||
# map -docstring 'pick file' global peneira f ': peneira-files<ret>'
|
||||
# map -docstring 'pick unopened file' global peneira F ': peneira-files -hide-opened<ret>'
|
||||
# map -docstring %{
|
||||
# pick line in buffer
|
||||
# } global peneira '/' ': peneira-lines<ret>'
|
||||
define-command -override -hidden consume %{
|
||||
nop %sh{
|
||||
niri msg action consume-or-expel-window-left
|
||||
}
|
||||
}
|
||||
|
||||
define-command terminal-consume %{
|
||||
terminal dash -c 'niri msg action consume-or-expel-window-left; exec fish'
|
||||
}
|
||||
|
||||
alias global tc terminal-consume
|
||||
|
||||
define-command -docstring %{
|
||||
Create a new client in vertial split
|
||||
} new-consume %{
|
||||
new consume
|
||||
}
|
||||
|
||||
alias global nc new-consume
|
||||
alias global n new
|
||||
define-command -docstring 'open popup shell' popup-shell %{
|
||||
popup fish
|
||||
}
|
||||
alias global pp popup-shell
|
||||
|
||||
map -docstring 'popup shell' global user . ': popup-shell<ret>'
|
||||
require-module ui-mode
|
||||
|
||||
try %{
|
||||
evaluate-commands %sh{kak-lsp-diags}
|
||||
map -docstring 'enable diagnostic hover' global ui "'" ': lsp-diag-hover-enable<ret>'
|
||||
map -docstring 'disable diagnostic hover' global ui '"' ': lsp-diag-hover-disable<ret>'
|
||||
}
|
||||
|
||||
define-command -docstring "New terminal in cwd" cwd-terminal %{
|
||||
terminal fish
|
||||
}
|
||||
# make easy to open new shell
|
||||
alias global t cwd-terminal
|
||||
|
||||
|
|
@ -14,102 +14,26 @@ define-command -override true nop
|
|||
define-command -override false fail
|
||||
|
||||
require-module ui-mode
|
||||
require-module colemak
|
||||
|
||||
try %{
|
||||
%opt{on_server}
|
||||
colorscheme ashen-local
|
||||
} catch %{
|
||||
evaluate-commands %sh{ kak-tree-sitter -dks --init $kak_session }
|
||||
evaluate-commands %sh{kak-popup init}
|
||||
# evaluate-commands %sh{ reflow init }
|
||||
# set-option global reflow_command %{
|
||||
# cat > "${input=$(mktemp)}"
|
||||
# # reflow --width "$kak_opt_reflow_width" --tabstop "$kak_opt_tabstop" < "$input" || cat "$input"
|
||||
# fmt -u < "$input" | perl -CS -pe 's/([.!?])\s{2,}/\1 /g' || cat "$input"
|
||||
# rm -f "$input"
|
||||
# }
|
||||
|
||||
colorscheme ashen
|
||||
require-module hop-kak
|
||||
require-module fishr
|
||||
require-module title-bar
|
||||
require-module notes
|
||||
require-module plugins
|
||||
require-module yazi
|
||||
require-module luar
|
||||
require-module clipboard
|
||||
set-option global luar_interpreter luajit
|
||||
# only set to foot if we are on wayland
|
||||
hook global ModuleLoaded wayland %{
|
||||
set-option global termcmd 'footclient dash -c'
|
||||
}
|
||||
# needed for tree-sitter to respect show-matching
|
||||
define-command -override tree-sitter-user-after-highlighter %{
|
||||
add-highlighter -override buffer/show-matching show-matching
|
||||
}
|
||||
|
||||
# manually requiring needed for some reason 😢
|
||||
# require-module peneira
|
||||
|
||||
# declare-user-mode peneira
|
||||
# map -docstring %{
|
||||
# Picker mode
|
||||
# } global user f ': enter-user-mode peneira<ret>'
|
||||
# map -docstring 'pick file' global peneira f ': peneira-files<ret>'
|
||||
# map -docstring 'pick unopened file' global peneira F ': peneira-files -hide-opened<ret>'
|
||||
# map -docstring %{
|
||||
# pick line in buffer
|
||||
# } global peneira '/' ': peneira-lines<ret>'
|
||||
define-command -override -hidden consume %{
|
||||
nop %sh{
|
||||
niri msg action consume-or-expel-window-left
|
||||
}
|
||||
}
|
||||
|
||||
define-command terminal-consume %{
|
||||
terminal dash -c 'niri msg action consume-or-expel-window-left; exec fish'
|
||||
}
|
||||
|
||||
alias global tc terminal-consume
|
||||
|
||||
define-command -docstring %{
|
||||
Create a new client in vertial split
|
||||
} new-consume %{
|
||||
new consume
|
||||
}
|
||||
|
||||
alias global nc new-consume
|
||||
alias global n new
|
||||
define-command -docstring 'open popup shell' popup-shell %{
|
||||
popup fish
|
||||
}
|
||||
alias global pp popup-shell
|
||||
|
||||
map -docstring 'popup shell' global user . ': popup-shell<ret>'
|
||||
require-module ui-mode
|
||||
|
||||
try %{
|
||||
evaluate-commands %sh{kak-lsp-diags}
|
||||
map -docstring 'enable diagnostic hover' global ui "'" ': lsp-diag-hover-enable<ret>'
|
||||
map -docstring 'disable diagnostic hover' global ui '"' ': lsp-diag-hover-disable<ret>'
|
||||
}
|
||||
source %exp{%val{config}/extra.kak}
|
||||
}
|
||||
|
||||
require-module surround
|
||||
require-module expand
|
||||
require-module ficgrep
|
||||
require-module byline
|
||||
require-module spell
|
||||
set-option global scrolloff 3,3
|
||||
|
||||
|
||||
|
||||
try %{
|
||||
set-option global ashen_dynamic_cursor true
|
||||
set-option global ashen_eol_cursor true
|
||||
}
|
||||
|
||||
|
||||
# disable clippy
|
||||
set-option -add global ui_options terminal_assistant=none
|
||||
|
||||
|
@ -225,13 +149,6 @@ define-command -params 1 -docstring "Set buffer filetype" filetype %{
|
|||
alias global ft filetype
|
||||
alias global lang filetype
|
||||
|
||||
define-command -docstring "New terminal in cwd" cwd-terminal %{
|
||||
terminal fish
|
||||
}
|
||||
# make easy to open new shell
|
||||
alias global t cwd-terminal
|
||||
|
||||
|
||||
map global normal <backspace> '"_'
|
||||
define-command goto-debug %{
|
||||
buffer *debug*
|
||||
|
@ -263,17 +180,6 @@ map -docstring 'save to jumplist' global normal <c-v> <c-s>
|
|||
# selection saving
|
||||
map -docstring 'add selection' global normal Y <a-Z>a
|
||||
|
||||
# hook -once global ClientCreate .* %{
|
||||
# evaluate-commands %sh{
|
||||
# if [ "$kak_buflist" != "*debug* *scratch*" ]; then
|
||||
# echo "delete-buffer *scratch*"
|
||||
# else
|
||||
# echo "echo -debug dumping buffers"
|
||||
# echo "echo -debug %val{buflist}"
|
||||
# fi
|
||||
# }
|
||||
# }
|
||||
|
||||
# open URL
|
||||
require-module url-open
|
||||
map -docstring "Open URL" global goto u '<esc>: url-open<ret>'
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue