diff --git a/nvim/.config/nvim/lazy-lock.json b/nvim/.config/nvim/lazy-lock.json index 77a53ba..17a3aec 100644 --- a/nvim/.config/nvim/lazy-lock.json +++ b/nvim/.config/nvim/lazy-lock.json @@ -3,6 +3,7 @@ "FixCursorHold.nvim": { "branch": "master", "commit": "1900f89dc17c603eec29960f57c00bd9ae696495" }, "Navigator.nvim": { "branch": "master", "commit": "91d86506ac2a039504d5205d32a1d4bc7aa57072" }, "bats.vim": { "branch": "master", "commit": "6a5d2ef22b0ede503d867770afd02ebb1f97b709" }, + "blink-copilot": { "branch": "main", "commit": "41e91a659bd9b8cba9ba2ea68a69b52ba5a9ebd8" }, "blink.cmp": { "branch": "main", "commit": "9bcb14b43852a6f2bfd5ac9ef29cb5cf09b1b39b" }, "blink.compat": { "branch": "main", "commit": "2ed6d9a28b07fa6f3bface818470605f8896408c" }, "cmp-calc": { "branch": "main", "commit": "5947b412da67306c5b68698a02a846760059be2e" }, diff --git a/nvim/.config/nvim/lua/plugins/llm.lua b/nvim/.config/nvim/lua/plugins/llm.lua index 38a90ba..7d90eaa 100644 --- a/nvim/.config/nvim/lua/plugins/llm.lua +++ b/nvim/.config/nvim/lua/plugins/llm.lua @@ -2,22 +2,79 @@ return { { -- NOTE: Requires manual auth with ':Copilot auth' or 'GH_COPILOT_TOKEN' set as envvar "zbirenbaum/copilot.lua", - dependencies = { "AndreM222/copilot-lualine" }, + dependencies = { + "AndreM222/copilot-lualine", + { -- show completions in blink + "saghen/blink.cmp", + optional = true, + dependencies = { + { + "fang2hou/blink-copilot", + opts = { + auto_refresh = { + backward = false, + forward = false, + }, + }, + }, + }, + opts = { + sources = { + default = { "copilot" }, + providers = { + copilot = { + name = "copilot", + module = "blink-copilot", + score_offset = 100, + async = true, + }, + }, + }, + }, + }, + }, cmd = "Copilot", - event = "InsertEnter", + event = { "InsertEnter", "VeryLazy" }, opts = { panel = { layout = { position = "bottom" } }, suggestion = { keymap = { accept = "" } }, + logger = { print_log_level = vim.log.levels.ERROR }, }, + config = function(_, opts) + require("copilot").setup(opts) + -- TODO: See also https://github.com/zbirenbaum/copilot.lua/issues/302 for potential + -- better solutions. + -- TODO: also Find way of having a 'toggle' for mapping below. + -- Current copilot.lua exposed 'toggle' command does NOT do the same. + require("copilot.command").disable() + end, keys = { { - "ap", + "aC", function() - -- FIXME: If opening before lazy-loaded, errors + require("copilot.panel").setup() require("copilot.panel").open({}) require("copilot.panel").refresh() end, - desc = "Refresh Copilot Panel", + desc = "Open copilot panel", + silent = true, + mode = { "n" }, + }, + { + "ap", + function() + require("copilot.command").enable() + end, + desc = "Enable copilot", + silent = true, + mode = { "n" }, + }, + { + "aP", + function() + require("copilot.command").disable() + end, + desc = "Disable copilot", silent = true, mode = { "n" }, }, diff --git a/office/.config/aerc/binds.conf b/office/.config/aerc/binds.conf index 1a2d6a4..5245faa 100644 --- a/office/.config/aerc/binds.conf +++ b/office/.config/aerc/binds.conf @@ -90,6 +90,8 @@ l = :view w = :filter tag:wait l = :filter tag:delegated +k = :terminal ikhal + d = :move Trash D = :choose -o y 'Really delete this message' :delete a = :archive flat # archive message @@ -209,7 +211,8 @@ x = :encrypt # Toggle encryption to all recipients v = :preview # Preview message p = :postpone # Postpone q = :choose -o d discard abort -o p postpone postpone # Abort or postpone -e = :edit # Edit (body and headers) +e = :edit -e # Edit, headers in-message +E = :edit -E # Edit, body and headers separate a = :attach -m # Add attachment d = :detach # Remove attachment diff --git a/office/.config/sh/alias.d/calcurse-vdir.sh b/office/.config/sh/alias.d/calcurse-vdir.sh deleted file mode 100644 index 91a8403..0000000 --- a/office/.config/sh/alias.d/calcurse-vdir.sh +++ /dev/null @@ -1,27 +0,0 @@ -#!/usr/bin/env sh -# -# Wraps around the calcurse invocation and syncs calendar data -# to local vdir - given by default below. -# -# For now ONLY PROVIDES ONE-WAY Synchronization, see below. - -# The path in which *the calendars* reside (i.e. toplevel with access to all paths) -CAL_PATH="$HOME/documents/calendars" - -calcurse() { - find "$CAL_PATH" -maxdepth 1 -type d -exec calcurse-vdir import {} \; -} - -# Enable two-way sync. One issue is that calcurse would sync everything -# into the top-level path (or the selected calendar path) since it makes -# not the same differentiation as the vdir between calendars. -# FIXME Not sure how to resolve currently. -# -# The below works as a simple two-way synchronization on exiting calcurse. -# To function the invocation has to be turned from a function above to an -# executable shell-script file instead. -# trap 'calcurse_export' 0 -# -# calcurse_export() { -# calcurse-vdir export "$CAL_PATH" -# } diff --git a/sh/.config/carapace/specs/cat.yaml b/sh/.config/carapace/specs/cat.yaml new file mode 100644 index 0000000..c73491b --- /dev/null +++ b/sh/.config/carapace/specs/cat.yaml @@ -0,0 +1,3 @@ +# yaml-language-server: $schema=https://carapace.sh/schemas/command.json +name: cat +run: "[bat]" diff --git a/terminal/.config/wezterm/maps.lua b/terminal/.config/wezterm/maps.lua index 57d0740..40cc692 100644 --- a/terminal/.config/wezterm/maps.lua +++ b/terminal/.config/wezterm/maps.lua @@ -52,6 +52,19 @@ local keys = { mods = "LEADER|CTRL", action = act.PaneSelect({ mode = "MoveToNewTab" }), }, + { + key = "R", + mods = "LEADER", + action = act.PromptInputLine({ + description = "Enter new name for tab", + action = wezterm.action_callback(function(win, _, line) + if line then + win:active_tab():set_title(line) + end + end), + }), + }, + { key = "c", mods = "LEADER", action = act.SpawnTab("CurrentPaneDomain") }, { key = ",", mods = "LEADER", action = act.ActivateTabRelative(-1) }, { key = ".", mods = "LEADER", action = act.ActivateTabRelative(1) }, -- workspace selection @@ -62,6 +75,7 @@ local keys = { mods = "LEADER", action = act.ShowLauncherArgs({ flags = "FUZZY|WORKSPACES" }), }, + { key = "t", mods = "LEADER", action = act.EmitEvent("toggle-tabbar") }, { key = "T", mods = "LEADER", action = act.ShowTabNavigator }, { key = "[", mods = "LEADER", action = act.ActivateCopyMode }, { @@ -105,7 +119,6 @@ local keys = { }, { key = "e", mods = "LEADER", action = act.EmitEvent("edit-scrollback") }, { key = "a", mods = "CTRL|ALT", action = act.EmitEvent("toggle-leader") }, - { key = "t", mods = "LEADER", action = act.EmitEvent("toggle-tabbar") }, { key = ":", mods = "LEADER|SHIFT",