AutoYADM commit: 2025-06-14 04:03:00

This commit is contained in:
Daniel Fichtinger 2025-06-14 04:03:00 -04:00
parent 5ffe0c53a3
commit 5c4975d4e2
3 changed files with 10 additions and 15 deletions

View file

@ -1,20 +1,18 @@
provide-module ltex-dict %~
declare-option str ltex_dict_path %exp{%val{config}/ltex-dict.txt}
declare-option -hidden str ltex_tomlize %{
'%<a-J>Zbi"<esc>a"<esc>z<a-,>r,x_i[<esc>a]<esc>'
}
define-command ltex-dict-set %{
# declare-option str foobartest ''
set-option buffer lsp_servers %sh{
# printf %s "$kak_opt_lsp_servers" | sed
list="$(cat "$kak_opt_ltex_dict_path" | kak -f '%<a-J>Zbi\"<esc>a\"<esc>z<a-,>r,x_i[<esc>a]<esc>')"
notify-send "$list"
# cat /tmp/lspconf.txt | sed "/^\s*dictionary =/ s/\[\]/$list/g"
list="$(cat "$kak_opt_ltex_dict_path" | kak -f '<a-o>%<a-J>Zbi\"<esc>a\"<esc>z<a-,>r,x_i[<esc>a]<esc>')"
echo "$kak_opt_lsp_servers" | sed "/^\s*dictionary =/ s/\[\]/$list/g"
}
echo -debug %opt{lsp_servers}
# echo -debug %opt{foobartest}
}
define-command ltex-add %{
evaluate-commands %sh{
if [ "$kak_selection_length" = 1 ]; then
printf 'execute-keys bw_<a-|>tee -a /tmp/test.txt'
}
}
~