From 45cc56b8c670946d7e24fe6c1a15f98c67010b02 Mon Sep 17 00:00:00 2001
From: Luca Bilke <luca@bil.ke>
Date: Thu, 17 Apr 2025 18:30:43 +0200
Subject: [PATCH 1/7] aichat: update submodule
---
submodules/.config/aichat/functions | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/submodules/.config/aichat/functions b/submodules/.config/aichat/functions
index 5cd7e71a..e5f9a980 160000
--- a/submodules/.config/aichat/functions
+++ b/submodules/.config/aichat/functions
@@ -1 +1 @@
-Subproject commit 5cd7e71a13b64661bff32a4f0166dcfdef07993d
+Subproject commit e5f9a9806cacd5795a25a80dac6150af818248eb
From 5a213280a1aa99a6c349d61fbd3fa8e4100c87fd Mon Sep 17 00:00:00 2001
From: Luca Bilke <luca@bil.ke>
Date: Tue, 6 May 2025 12:01:54 +0200
Subject: [PATCH 2/7] zsh: rebind ctrl-w to ctrl-bs
---
common/.config/zsh/config/bindings.zsh | 75 +++++++++++++-------------
1 file changed, 38 insertions(+), 37 deletions(-)
diff --git a/common/.config/zsh/config/bindings.zsh b/common/.config/zsh/config/bindings.zsh
index a817acd3..0245c4b5 100644
--- a/common/.config/zsh/config/bindings.zsh
+++ b/common/.config/zsh/config/bindings.zsh
@@ -5,39 +5,40 @@ zmodload zsh/terminfo
typeset -gA key_info
key_info=(
- 'Control' "\C-"
- 'Escape' "\e"
- 'Meta' "\M-"
- 'Backspace' "^?"
- 'Delete' "^[[3~"
- 'F1' "$terminfo[kf1]"
- 'F2' "$terminfo[kf2]"
- 'F3' "$terminfo[kf3]"
- 'F4' "$terminfo[kf4]"
- 'F5' "$terminfo[kf5]"
- 'F6' "$terminfo[kf6]"
- 'F7' "$terminfo[kf7]"
- 'F8' "$terminfo[kf8]"
- 'F9' "$terminfo[kf9]"
- 'F10' "$terminfo[kf10]"
- 'F11' "$terminfo[kf11]"
- 'F12' "$terminfo[kf12]"
- 'Insert' "$terminfo[kich1]"
- 'Home' "$terminfo[khome]"
- 'PageUp' "$terminfo[kpp]"
- 'End' "$terminfo[kend]"
- 'PageDown' "$terminfo[knp]"
- 'Up' "$terminfo[kcuu1]"
- 'Left' "$terminfo[kcub1]"
- 'Down' "$terminfo[kcud1]"
- 'Right' "$terminfo[kcuf1]"
- 'BackTab' "$terminfo[kcbt]"
- 'AltLeft' "${key_info[Escape]}${key_info[Left]} \e[1;3D"
- 'AltRight' "${key_info[Escape]}${key_info[Right]} \e[1;3C"
- 'ControlLeft' "\e[1;5D"
- 'ControlRight' "\e[1;5C"
- 'ControlPageUp' "\e[5;5~"
- 'ControlPageDown' "\e[6;5~"
+ 'Control' "\C-"
+ 'Escape' "\e"
+ 'Meta' "\M-"
+ 'Backspace' "^?"
+ 'ControlBackspace' "^H"
+ 'Delete' "^[[3~"
+ 'F1' "$terminfo[kf1]"
+ 'F2' "$terminfo[kf2]"
+ 'F3' "$terminfo[kf3]"
+ 'F4' "$terminfo[kf4]"
+ 'F5' "$terminfo[kf5]"
+ 'F6' "$terminfo[kf6]"
+ 'F7' "$terminfo[kf7]"
+ 'F8' "$terminfo[kf8]"
+ 'F9' "$terminfo[kf9]"
+ 'F10' "$terminfo[kf10]"
+ 'F11' "$terminfo[kf11]"
+ 'F12' "$terminfo[kf12]"
+ 'Insert' "$terminfo[kich1]"
+ 'Home' "$terminfo[khome]"
+ 'PageUp' "$terminfo[kpp]"
+ 'End' "$terminfo[kend]"
+ 'PageDown' "$terminfo[knp]"
+ 'Up' "$terminfo[kcuu1]"
+ 'Left' "$terminfo[kcub1]"
+ 'Down' "$terminfo[kcud1]"
+ 'Right' "$terminfo[kcuf1]"
+ 'BackTab' "$terminfo[kcbt]"
+ 'AltLeft' "${key_info[Escape]}${key_info[Left]} \e[1;3D"
+ 'AltRight' "${key_info[Escape]}${key_info[Right]} \e[1;3C"
+ 'ControlLeft' "\e[1;5D"
+ 'ControlRight' "\e[1;5C"
+ 'ControlPageUp' "\e[5;5~"
+ 'ControlPageDown' "\e[6;5~"
)
local -A global_keybinds
@@ -57,10 +58,10 @@ global_keybinds=(
local -A viins_keybinds
viins_keybinds=(
- "$key_info[Control]W" backward-kill-word
- "$key_info[Backspace]" backward-delete-char
- "$key_info[ControlLeft]" vi-backward-word
- "$key_info[ControlRight]" vi-forward-word
+ "$key_info[ControlBackspace]" backward-kill-word
+ "$key_info[Backspace]" backward-delete-char
+ "$key_info[ControlLeft]" vi-backward-word
+ "$key_info[ControlRight]" vi-forward-word
)
local -A vicmd_keybinds
From 6dbd9356553554a46c880f1cf30640c79b35b746 Mon Sep 17 00:00:00 2001
From: Luca Bilke <luca@bil.ke>
Date: Tue, 6 May 2025 12:01:59 +0200
Subject: [PATCH 3/7] libsb: cleanup
---
common/.local/libexec/statusbar/libsb | 1 -
1 file changed, 1 deletion(-)
diff --git a/common/.local/libexec/statusbar/libsb b/common/.local/libexec/statusbar/libsb
index ad265d2c..3c8a5cf8 100755
--- a/common/.local/libexec/statusbar/libsb
+++ b/common/.local/libexec/statusbar/libsb
@@ -23,7 +23,6 @@ export bggray="background='#414868$bgalpha'"
export bgwhite="background='#C0CAF5$bgalpha'"
meter_bar() {
- # shellcheck disable=SC2194
case $1 in
9[0-9] | 100) color="$fgred" bar="▉" ;;
8[0-9]) color="$fgred" bar="█" ;;
From 728876825e4eb52dc753d3d9b95f7f79fa5e196b Mon Sep 17 00:00:00 2001
From: Luca Bilke <luca@bil.ke>
Date: Tue, 6 May 2025 16:59:04 +0200
Subject: [PATCH 4/7] lf: update trash-restore for updated tool
---
common/.config/lf/lfrc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/common/.config/lf/lfrc b/common/.config/lf/lfrc
index ed9b1452..4bb7aa3a 100644
--- a/common/.config/lf/lfrc
+++ b/common/.config/lf/lfrc
@@ -31,7 +31,7 @@ cmd trash &{{
cmd trash-restore ${{
fileid=$(
- trash-util list "$PWD" |
+ trash-util list -f null "$PWD" |
fzf -d '\0' \
--with-nth=1 \
--nth=1 \
From 10fa8a0d49b7ce8fb1858bf0ec2f20a187e6ae4a Mon Sep 17 00:00:00 2001
From: Luca Bilke <luca@bil.ke>
Date: Tue, 6 May 2025 16:59:20 +0200
Subject: [PATCH 5/7] nvim: reconfigure avante, copilot keybinds
---
common/.config/nvim/lua/plugins/ai.lua | 17 +++--------------
1 file changed, 3 insertions(+), 14 deletions(-)
diff --git a/common/.config/nvim/lua/plugins/ai.lua b/common/.config/nvim/lua/plugins/ai.lua
index 16623c1d..afaa69f2 100644
--- a/common/.config/nvim/lua/plugins/ai.lua
+++ b/common/.config/nvim/lua/plugins/ai.lua
@@ -30,6 +30,9 @@ return {
provider_opts = {},
},
},
+ keys = {
+ { "<leader>aC", "<cmd>AvanteClear<cr>", desc = "avante: Clear" },
+ },
build = "make",
},
{
@@ -87,20 +90,6 @@ return {
[""] = false,
},
},
- keys = {
- { "<leader>a", group = "ai" },
- {
- "<leader>aT",
- "<CMD>Copilot toggle<CR>",
- desc = "copilot: toggle",
- },
- },
- },
- { -- temporary fix
- "nvim-lualine/lualine.nvim",
- opts = function(_, opts)
- table.remove(opts.sections.lualine_x, 2)
- end,
},
{
"folke/which-key.nvim",
From 3d998a49c3ef56f96a2be5d070655a6b604e57de Mon Sep 17 00:00:00 2001
From: Luca Bilke <luca@bil.ke>
Date: Thu, 8 May 2025 17:15:05 +0200
Subject: [PATCH 6/7] lf: edit j2 with nvim
---
common/.config/lf/rifle.conf | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/common/.config/lf/rifle.conf b/common/.config/lf/rifle.conf
index c3636543..9009c131 100644
--- a/common/.config/lf/rifle.conf
+++ b/common/.config/lf/rifle.conf
@@ -16,10 +16,10 @@ ext x?html?, has w3m, terminal = w3m "$@"
#-------------------------------------------
# Misc
#-------------------------------------------
-label editor, mime ^text|x-empty$ = ${VISUAL:-$EDITOR} -- "$@"
-label pager, mime ^text|x-empty$ = $PAGER -- "$@"
-label editor, ext xml|json|csv|tex|py|pl|rb|rs|js|sh|php|dart = ${VISUAL:-$EDITOR} -- "$@"
-label pager, ext xml|json|csv|tex|py|pl|rb|rs|js|sh|php|dart = $PAGER -- "$@"
+label editor, mime ^text|x-empty$ = ${VISUAL:-$EDITOR} -- "$@"
+label pager, mime ^text|x-empty$ = $PAGER -- "$@"
+label editor, ext xml|json|csv|tex|py|pl|rb|rs|js|sh|php|dart|j2 = ${VISUAL:-$EDITOR} -- "$@"
+label pager, ext xml|json|csv|tex|py|pl|rb|rs|js|sh|php|dart|j2 = $PAGER -- "$@"
#--------------------------------------------
# Audio without X
From 937e5bfd245893b4215c846ac7e5870d20362022 Mon Sep 17 00:00:00 2001
From: Luca Bilke <luca@bil.ke>
Date: Thu, 8 May 2025 17:15:15 +0200
Subject: [PATCH 7/7] nvim: cleanup
---
common/.config/nvim/init.lua | 21 -----------------
common/.config/nvim/lua/config/autocmds.lua | 26 +++++++++++++++++++++
common/.config/nvim/lua/config/options.lua | 3 ++-
common/.config/nvim/lua/plugins/ai.lua | 2 +-
4 files changed, 29 insertions(+), 23 deletions(-)
create mode 100644 common/.config/nvim/lua/config/autocmds.lua
diff --git a/common/.config/nvim/init.lua b/common/.config/nvim/init.lua
index 88410970..0cb6e4b4 100644
--- a/common/.config/nvim/init.lua
+++ b/common/.config/nvim/init.lua
@@ -73,24 +73,3 @@ require("lazy").setup({
},
},
})
-
-for _, autocmd in ipairs({
- { -- Automatically change line numeration
- { "BufEnter", "FocusGained", "InsertLeave", "WinEnter" },
- { command = 'if &nu && mode() != "i" | set rnu | endif' },
- },
- { -- Automatically change line numeration
- { "BufLeave", "FocusLost", "InsertEnter", "WinLeave" },
- { command = "if &nu | set nornu | endif" },
- },
- { -- Trigger shortcuts script
- "BufWritePost",
- { pattern = { "directories", "files" }, command = "silent!!shortcuts" },
- },
- { -- Trigger xrdb
- "BufWritePost",
- { pattern = { "xresources" }, command = "silent!!xrdb %" },
- },
-}) do
- vim.api.nvim_create_autocmd(autocmd[1], autocmd[2])
-end
diff --git a/common/.config/nvim/lua/config/autocmds.lua b/common/.config/nvim/lua/config/autocmds.lua
new file mode 100644
index 00000000..eb43940f
--- /dev/null
+++ b/common/.config/nvim/lua/config/autocmds.lua
@@ -0,0 +1,26 @@
+for _, autocmd in ipairs({
+ { -- Automatically change line numeration
+ { "BufEnter", "FocusGained", "InsertLeave", "WinEnter" },
+ { command = 'if &nu && mode() != "i" | set rnu | endif' },
+ },
+ { -- Automatically change line numeration
+ { "BufLeave", "FocusLost", "InsertEnter", "WinLeave" },
+ { command = "if &nu | set nornu | endif" },
+ },
+ { -- Trigger shortcuts script
+ "BufWritePost",
+ { pattern = { "directories", "files" }, command = "silent!!shortcuts" },
+ },
+ { -- Trigger xrdb
+ "BufWritePost",
+ { pattern = { "xresources" }, command = "silent!!xrdb %" },
+ },
+}) do
+ vim.api.nvim_create_autocmd(autocmd[1], autocmd[2])
+end
+
+for _, augroup in ipairs({
+ "lazyvim_wrap_spell",
+}) do
+ vim.api.nvim_del_augroup_by_name(augroup)
+end
diff --git a/common/.config/nvim/lua/config/options.lua b/common/.config/nvim/lua/config/options.lua
index 3075ec5f..302394f9 100644
--- a/common/.config/nvim/lua/config/options.lua
+++ b/common/.config/nvim/lua/config/options.lua
@@ -9,10 +9,11 @@ o.shiftwidth = 4
o.tabstop = 4
o.scrolloff = 8
o.conceallevel = 0
+o.smoothscroll = false
g.lazyvim_php_lsp = "intelephense"
g.lazyvim_python_lsp = "basedpyright"
-g.ai_cm = true
+g.ai_cmp = true
g.autoformat = false
g.snacks_animate = false
g.zk_notebook_dir = os.getenv("HOME") .. "/Public/notes"
diff --git a/common/.config/nvim/lua/plugins/ai.lua b/common/.config/nvim/lua/plugins/ai.lua
index afaa69f2..ff379897 100644
--- a/common/.config/nvim/lua/plugins/ai.lua
+++ b/common/.config/nvim/lua/plugins/ai.lua
@@ -1,7 +1,7 @@
return {
{
"yetone/avante.nvim",
- event = "VeryLazy",
+ event = "BufReadPost",
dependencies = {
"stevearc/dressing.nvim",
"ibhagwan/fzf-lua",