From 9efd89702f6897b1612fe4599db9d7650637007e Mon Sep 17 00:00:00 2001 From: Nulo Date: Thu, 16 Dec 2021 16:16:19 -0300 Subject: [PATCH] kak: kakoune-buffers --- .config/kak/kakrc | 18 ++++++++++++++++++ .config/kak/plugins/kakoune-buffers | 1 + .gitmodules | 3 +++ 3 files changed, 22 insertions(+) create mode 160000 .config/kak/plugins/kakoune-buffers diff --git a/.config/kak/kakrc b/.config/kak/kakrc index ccfb622..01f8e47 100644 --- a/.config/kak/kakrc +++ b/.config/kak/kakrc @@ -95,3 +95,21 @@ evaluate-commands %sh{ find -L "$kak_config/plugins/fzf.kak/rc/modules/" -type f -name '*.kak' -exec printf 'source "%s"\n' {} \; } map global normal ': fzf-modef' + +# ------------ +# Buffer switching +# ------------ +source "%val{config}/plugins/kakoune-buffers/buffers.kak" + +hook global WinDisplay .* info-buffers + +map global normal ^ q +map global normal Q + +map global normal q b +map global normal Q B +map global normal +map global normal + +map global normal b ':enter-buffers-mode' -docstring 'buffers…' +map global normal B ':enter-user-mode -lock buffers' -docstring 'buffers (lock)…' diff --git a/.config/kak/plugins/kakoune-buffers b/.config/kak/plugins/kakoune-buffers new file mode 160000 index 0000000..6b2081f --- /dev/null +++ b/.config/kak/plugins/kakoune-buffers @@ -0,0 +1 @@ +Subproject commit 6b2081f5b7d58c72de319a5cba7bf628b6802881 diff --git a/.gitmodules b/.gitmodules index d89e8c0..d4cca32 100644 --- a/.gitmodules +++ b/.gitmodules @@ -43,3 +43,6 @@ [submodule ".config/kak/plugins/fzf.kak"] path = .config/kak/plugins/fzf.kak url = https://github.com/andreyorst/fzf.kak +[submodule ".config/kak/plugins/kakoune-buffers"] + path = .config/kak/plugins/kakoune-buffers + url = https://github.com/Delapouite/kakoune-buffers