From cf153808a20641800b8fd0b8f74d326ab0c292b8 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Sat, 10 Feb 2024 13:27:37 +0100 Subject: [PATCH 01/29] nvim: Switch to mini base16 plugin Since we already have the mini library installed in our setup, we don't need to make use of external base16 plugins. It provides the same exact functionality, and seems slim and bug-free. Nothing changes for the user, but we have 1 plugin less to take care of (and it was mis-behaving in new versions anyway). Also set lualine to be reloaded on theme switch so it takes on the colorscheme as well. --- .../templates/nvim/templates/default.mustache | 37 ++++++++++--------- nvim/.config/nvim/lua/plugins/config/mini.lua | 19 ++++++++++ nvim/.config/nvim/lua/plugins/core.lua | 27 +------------- 3 files changed, 40 insertions(+), 43 deletions(-) diff --git a/desktop/.config/flavours/templates/nvim/templates/default.mustache b/desktop/.config/flavours/templates/nvim/templates/default.mustache index 08baf2c..c2cd8de 100644 --- a/desktop/.config/flavours/templates/nvim/templates/default.mustache +++ b/desktop/.config/flavours/templates/nvim/templates/default.mustache @@ -7,23 +7,26 @@ -- by RRethy (https://github.com/RRethy/nvim-base16) -- {{scheme-name}} scheme by {{scheme-author}} -require('base16-colorscheme').setup({ - base00 = '#{{base00-hex}}', - base01 = '#{{base01-hex}}', - base02 = '#{{base02-hex}}', - base03 = '#{{base03-hex}}', - base04 = '#{{base04-hex}}', - base05 = '#{{base05-hex}}', - base06 = '#{{base06-hex}}', - base07 = '#{{base07-hex}}', - base08 = '#{{base08-hex}}', - base09 = '#{{base09-hex}}', - base0A = '#{{base0A-hex}}', - base0B = '#{{base0B-hex}}', - base0C = '#{{base0C-hex}}', - base0D = '#{{base0D-hex}}', - base0E = '#{{base0E-hex}}', - base0F = '#{{base0F-hex}}' +require('mini.base16').setup({ + palette = { + base00 = '#{{base00-hex}}', + base01 = '#{{base01-hex}}', + base02 = '#{{base02-hex}}', + base03 = '#{{base03-hex}}', + base04 = '#{{base04-hex}}', + base05 = '#{{base05-hex}}', + base06 = '#{{base06-hex}}', + base07 = '#{{base07-hex}}', + base08 = '#{{base08-hex}}', + base09 = '#{{base09-hex}}', + base0A = '#{{base0A-hex}}', + base0B = '#{{base0B-hex}}', + base0C = '#{{base0C-hex}}', + base0D = '#{{base0D-hex}}', + base0E = '#{{base0E-hex}}', + base0F = '#{{base0F-hex}}' + }, }) +require('lualine').setup() -- vim: filetype=lua diff --git a/nvim/.config/nvim/lua/plugins/config/mini.lua b/nvim/.config/nvim/lua/plugins/config/mini.lua index 8a9b55c..6275595 100644 --- a/nvim/.config/nvim/lua/plugins/config/mini.lua +++ b/nvim/.config/nvim/lua/plugins/config/mini.lua @@ -1,3 +1,20 @@ +local colorsfile = vim.fn.stdpath("state") .. "/colorscheme.lua" +local function source_colors() + if vim.fn.filereadable(colorsfile) == 1 then + vim.cmd("source " .. colorsfile) + end +end +-- set on startup +source_colors() + +-- continuously watch colors file for changes +local fwatch = require("fwatch") +fwatch.watch(colorsfile, { + on_event = vim.schedule_wrap(function() + source_colors() + end), +}) + require("mini.ai").setup() require("mini.comment").setup({ hooks = { @@ -8,11 +25,13 @@ require("mini.comment").setup({ }) require("mini.cursorword").setup({ delay = 500 }) require("mini.fuzzy").setup() + require("mini.indentscope").setup({ symbol = "│", draw = { animation = require("mini.indentscope").gen_animation.none() }, options = { indent_at_cursor = false }, }) + require("mini.map").setup() require("mini.move").setup() -- has not hit stable yet require("mini.pairs").setup() diff --git a/nvim/.config/nvim/lua/plugins/core.lua b/nvim/.config/nvim/lua/plugins/core.lua index f317b39..cbcbb23 100644 --- a/nvim/.config/nvim/lua/plugins/core.lua +++ b/nvim/.config/nvim/lua/plugins/core.lua @@ -57,6 +57,7 @@ return { { "echasnovski/mini.nvim", version = "*", + dependencies = { "rktjmp/fwatch.nvim" }, config = function() require("plugins.config.mini") end, @@ -86,32 +87,6 @@ return { { "sP", ":Pythonterm!" }, }, }, - -- colorschemes - { - "RRethy/nvim-base16", - lazy = false, - commit = "96e3089", - priority = 1000, - dependencies = { "rktjmp/fwatch.nvim" }, - config = function() - local colorsfile = vim.fn.stdpath("state") .. "/colorscheme.lua" - local function source_colors() - if vim.fn.filereadable(colorsfile) == 1 then - vim.cmd("source " .. colorsfile) - end - end - -- set on startup - source_colors() - - -- continuously watch colors file for changes - local fwatch = require("fwatch") - fwatch.watch(colorsfile, { - on_event = vim.schedule_wrap(function() - source_colors() - end), - }) - end, - }, -- try to avoid putting files in util buffers, e.g. filetree, aerial, undotree, .. { "stevearc/stickybuf.nvim", config = true }, -- make it a little less painful to open really big (>2mb) files by disabling features From 7e3377d60d089fae3507f307990d063e418e1943 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Sat, 10 Feb 2024 13:36:42 +0100 Subject: [PATCH 02/29] nvim: Update spellfile --- nvim/.config/nvim/spell/en.utf-8.add | 3 +++ 1 file changed, 3 insertions(+) diff --git a/nvim/.config/nvim/spell/en.utf-8.add b/nvim/.config/nvim/spell/en.utf-8.add index f19a7b4..365a643 100644 --- a/nvim/.config/nvim/spell/en.utf-8.add +++ b/nvim/.config/nvim/spell/en.utf-8.add @@ -209,3 +209,6 @@ redistributional HIC LMIC hukou +Theil +unobservables +familialization From 683cd64b26047dabca8b1989ee7b9386f023c044 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Sat, 10 Feb 2024 13:37:14 +0100 Subject: [PATCH 03/29] nvim: Lazy load editing plugins after entering insert --- nvim/.config/nvim/lua/plugins/editing.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nvim/.config/nvim/lua/plugins/editing.lua b/nvim/.config/nvim/lua/plugins/editing.lua index 70d59dc..67e08ed 100644 --- a/nvim/.config/nvim/lua/plugins/editing.lua +++ b/nvim/.config/nvim/lua/plugins/editing.lua @@ -2,7 +2,7 @@ return { -- adds exchange operator with cx. common use: cxiw . on 2 words to switch { "tommcdo/vim-exchange", - event = "VeryLazy", + event = "InsertEnter", }, -- Align tables and other alignable things { @@ -14,7 +14,7 @@ return { }, }, -- surround things with other things using ys/cs/ds - { "kylechui/nvim-surround", version = "*", config = true, event = "VeryLazy" }, + { "kylechui/nvim-surround", config = true, event = "InsertEnter" }, -- extend the ^a / ^x possibilities to dates, hex, alphabets, markdown headers { From 7e65c420013b90ef91e439ec5d3108a744e5d734 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Sat, 10 Feb 2024 13:39:44 +0100 Subject: [PATCH 04/29] nvim: Update plugins --- nvim/.config/nvim/lazy-lock.json | 49 ++++++++++++++------------------ 1 file changed, 22 insertions(+), 27 deletions(-) diff --git a/nvim/.config/nvim/lazy-lock.json b/nvim/.config/nvim/lazy-lock.json index f28ea72..348ffc7 100644 --- a/nvim/.config/nvim/lazy-lock.json +++ b/nvim/.config/nvim/lazy-lock.json @@ -4,15 +4,13 @@ "FixCursorHold.nvim": { "branch": "master", "commit": "1900f89dc17c603eec29960f57c00bd9ae696495" }, "LuaSnip": { "branch": "master", "commit": "8ae1dedd988eb56441b7858bd1e8554dfadaa46d" }, "Navigator.nvim": { "branch": "master", "commit": "91d86506ac2a039504d5205d32a1d4bc7aa57072" }, - "aerial.nvim": { "branch": "master", "commit": "63ec2bfc3d9b8ce1fd943fff14781504d8ee250e" }, + "aerial.nvim": { "branch": "master", "commit": "3748e87a316a68754341cdffcef44fee61dee51c" }, "bats.vim": { "branch": "master", "commit": "6a5d2ef22b0ede503d867770afd02ebb1f97b709" }, - "bigfile.nvim": { "branch": "main", "commit": "33eb067e3d7029ac77e081cfe7c45361887a311a" }, "cmp-beancount": { "branch": "main", "commit": "da154ea94d598e6649d6ad01efa0a8611eff460d" }, "cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" }, "cmp-calc": { "branch": "main", "commit": "ce91d14d2e7a8b3f6ad86d85e34d41c1ae6268d9" }, "cmp-cmdline": { "branch": "main", "commit": "8ee981b4a91f536f52add291594e89fb6645e451" }, "cmp-digraphs": { "branch": "master", "commit": "5efc1f0078d7c5f3ea1c8e3aad04da3fd6e081a9" }, - "cmp-latex-symbols": { "branch": "main", "commit": "165fb66afdbd016eaa1570e41672c4c557b57124" }, "cmp-nvim-lsp": { "branch": "main", "commit": "5af77f54de1b16c34b23cba810150689a3a90312" }, "cmp-nvim-lsp-signature-help": { "branch": "main", "commit": "3d8912ebeb56e5ae08ef0906e3a54de1c66b92f1" }, "cmp-nvim-lua": { "branch": "main", "commit": "f12408bdb54c39c23e67cab726264c10db33ada8" }, @@ -20,50 +18,47 @@ "cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" }, "cmp-rg": { "branch": "master", "commit": "677a7874ee8f1afc648c2e7d63a97bc21a7663c5" }, "cmp-spell": { "branch": "master", "commit": "32a0867efa59b43edbb2db67b0871cfad90c9b66" }, - "cmp-tmux": { "branch": "main", "commit": "97ec06b8030b8bf6d1fd83d49bdd16c98e04c845" }, "cmp-treesitter": { "branch": "master", "commit": "13e4ef8f4dd5639fca2eb9150e68f47639a9b37d" }, "cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" }, "completion-vcard": { "branch": "master", "commit": "2220fd517a985ececed1adcf0e5be8f2815564c7" }, - "conform.nvim": { "branch": "master", "commit": "cbc5745bf7519acaf3a5cbaaa677fd556aa813d7" }, + "conform.nvim": { "branch": "master", "commit": "3d59cbd01a4b74124c5a6fb23b8cc63e5c2db3d5" }, "dial.nvim": { "branch": "master", "commit": "54b503f906bc9e5ab85288414840a1b86d40769f" }, - "dressing.nvim": { "branch": "master", "commit": "8b7ae53d7f04f33be3439a441db8071c96092d19" }, - "fidget.nvim": { "branch": "main", "commit": "3a93300c076109d86c7ce35ec67a8034ae6ba9db" }, - "friendly-snippets": { "branch": "main", "commit": "69a2c1675b66e002799f5eef803b87a12f593049" }, + "dressing.nvim": { "branch": "master", "commit": "42d767b04c50a6966c9633e3968bc65c0c2f2bfc" }, + "fidget.nvim": { "branch": "main", "commit": "a3e1e79116ceb93d4c8c0ff432bf506b3213a24d" }, + "friendly-snippets": { "branch": "main", "commit": "b8fae73a479ae0a1c54f5c98fa687ae8a0addc53" }, "fwatch.nvim": { "branch": "main", "commit": "a691f7349dc66285cd75a1a698dd28bca45f2bf8" }, - "git-conflict.nvim": { "branch": "main", "commit": "4e0191c9a0ae05d7fbdcdc7f15cd358f56d23bfb" }, + "git-conflict.nvim": { "branch": "main", "commit": "4c8e252b87d54d944c1e56bfb477f78b6fdaf661" }, "gitsigns.nvim": { "branch": "main", "commit": "6ef8c54fb526bf3a0bc4efb0b2fe8e6d9a7daed2" }, - "headlines.nvim": { "branch": "master", "commit": "e3d7bfdf40e41a020d966d35f8b48d75b90367d2" }, + "headlines.nvim": { "branch": "master", "commit": "d39c4e6ed8963717bc9b2dc39fada8fe1039e9bf" }, "image.nvim": { "branch": "master", "commit": "9b6248bd8b58b505559e31eb581b7c4638369ec3" }, - "lazy.nvim": { "branch": "main", "commit": "96584866b9c5e998cbae300594d0ccfd0c464627" }, + "lazy.nvim": { "branch": "main", "commit": "28126922c9b54e35a192ac415788f202c3944c9f" }, "lightspeed.nvim": { "branch": "main", "commit": "fcc72d8a4d5f4ebba62d8a3a0660f88f1b5c3b05" }, "lsp-setup.nvim": { "branch": "main", "commit": "22ba14fb5c4208fd93f616d7b99bb47656e6e144" }, - "lualine.nvim": { "branch": "master", "commit": "566b7036f717f3d676362742630518a47f132fff" }, + "lualine.nvim": { "branch": "master", "commit": "7d131a8d3ba5016229e8a1d08bf8782acea98852" }, "markdown-preview.nvim": { "branch": "master", "commit": "9becceee5740b7db6914da87358a183ad11b2049" }, "markmap.nvim": { "branch": "main", "commit": "3befc2a54c2448a16c30c1c7762aab263f22946a" }, "mason-lspconfig.nvim": { "branch": "main", "commit": "56e435e09f8729af2d41973e81a0db440f8fe9c9" }, "mason-tool-installer.nvim": { "branch": "main", "commit": "bf0f4f8062d3acbe0afcc61db01a4d19d96310e4" }, - "mason.nvim": { "branch": "main", "commit": "baf99d94c3380640d19af9c70c0541bd6e7cd0cb" }, - "mdeval.nvim": { "branch": "master", "commit": "2c32e2f3e7d8f222e7a4724989f218d036e1081d" }, + "mason.nvim": { "branch": "main", "commit": "c43eeb5614a09dc17c03a7fb49de2e05de203924" }, "mini.nvim": { "branch": "main", "commit": "b5645ac6eefce8e7af9d7dd4e5e296a81cba8a10" }, - "molten-nvim": { "branch": "main", "commit": "c263b4df09b14ed5245f0a15381d3363c2edf05a" }, - "neotest": { "branch": "master", "commit": "1ee3fcc150207f33dba8c9b3f478e5a0148d661d" }, + "molten-nvim": { "branch": "main", "commit": "21d766c2d60e5f6e03f507e7f3e382a2a927ad41" }, + "neogen": { "branch": "main", "commit": "cb1f384df804c1bf729332c4f728253fe17962d4" }, + "neotest": { "branch": "master", "commit": "b47c99265253f0a31a428b698c59ec0bc956e78d" }, "neotest-python": { "branch": "master", "commit": "81d2265efac717bb567bc15cc652ae10801286b3" }, - "nvim-FeMaco.lua": { "branch": "main", "commit": "6af458f0196215f397db31a6e1fb2df795811693" }, - "nvim-base16": { "branch": "master", "commit": "96e308958625a84940d5e443475465abf99c7bd9" }, - "nvim-cmp": { "branch": "main", "commit": "538e37ba87284942c1d76ed38dd497e54e65b891" }, + "nvim-cmp": { "branch": "main", "commit": "04e0ca376d6abdbfc8b52180f8ea236cbfddf782" }, "nvim-colorizer.lua": { "branch": "master", "commit": "85855b38011114929f4058efc97af1059ab3e41d" }, "nvim-coverage": { "branch": "main", "commit": "cf4b5c61dfac977026a51a2bcad9173c272986ce" }, - "nvim-lint": { "branch": "master", "commit": "6427b17058a74891bb287b275356bbc445b5924c" }, - "nvim-lspconfig": { "branch": "master", "commit": "7eed8b2150192e5ad05e1886fdf133493ddf2928" }, + "nvim-lint": { "branch": "master", "commit": "966ab3dc37eee3e413692264b44a3011b05a6060" }, + "nvim-lspconfig": { "branch": "master", "commit": "41f40dc4b86f3e166cf08115f621001972565a20" }, "nvim-surround": { "branch": "main", "commit": "703ec63aa798e5e07d309b35e42def34bebe0174" }, "nvim-toggleterm.lua": { "branch": "main", "commit": "cbd041d91b90cd3c02df03fe6133208888f8e008" }, "nvim-tree.lua": { "branch": "master", "commit": "f1b3e6a7eb92da492bd693257367d9256839ed3d" }, - "nvim-treesitter": { "branch": "master", "commit": "63260da18bf273c76b8e2ea0db84eb901cab49ce" }, - "nvim-treesitter-context": { "branch": "master", "commit": "2017a0d7fc2d3790d823feddedada506984a10ce" }, + "nvim-treesitter": { "branch": "master", "commit": "f197a15b0d1e8d555263af20add51450e5aaa1f0" }, + "nvim-treesitter-context": { "branch": "master", "commit": "9c06b115abc57c99cf0aa81dc29490f5001f57a1" }, "nvim-treesitter-endwise": { "branch": "master", "commit": "4c344ffc8d54d7e1ba2cefaaa2c10ea93aa1cc2d" }, "nvim-treesitter-textsubjects": { "branch": "master", "commit": "55d11124c45e9bb506703f73e5775652ed5357e9" }, - "nvim-ts-autotag": { "branch": "main", "commit": "8515e48a277a2f4947d91004d9aa92c29fdc5e18" }, - "nvim-ts-context-commentstring": { "branch": "main", "commit": "1277b4a1f451b0f18c0790e1a7f12e1e5fdebfee" }, + "nvim-ts-autotag": { "branch": "main", "commit": "531f48334c422222aebc888fd36e7d109cb354cd" }, + "nvim-ts-context-commentstring": { "branch": "main", "commit": "7ab799a9792f7cf3883cf28c6a00ad431f3d382a" }, "nvim-ts-rainbow2": { "branch": "master", "commit": "b3120cd5ae9ca524af9cb602f41e12e301fa985f" }, "nvim-web-devicons": { "branch": "master", "commit": "a55b801b7ef5719ca25692c3a0a5447fdfb692ed" }, "otter.nvim": { "branch": "main", "commit": "cf29fc255bce78fd03565b40722438c0ab3ce05d" }, @@ -76,11 +71,11 @@ "telescope.nvim": { "branch": "master", "commit": "d90956833d7c27e73c621a61f20b29fdb7122709" }, "trouble.nvim": { "branch": "main", "commit": "f1168feada93c0154ede4d1fe9183bf69bac54ea" }, "twilight.nvim": { "branch": "main", "commit": "8bb7fa7b918baab1ca81b977102ddb54afa63512" }, - "undotree": { "branch": "main", "commit": "80552a0180b49e5ba072c89ae91ce5d4e3aed36b" }, + "undotree": { "branch": "main", "commit": "eab459ab87dd249617b5f7187bb69e614a083047" }, "vifm.vim": { "branch": "master", "commit": "a8130c37d144b51d84bee19f0532abcd3583383f" }, "vim-criticmarkup": { "branch": "master", "commit": "d15dc134eb177a170c79f6377f81eb02a9d20b02" }, "vim-easy-align": { "branch": "master", "commit": "0db4ea6132110631ec678a99a82aa49a0686ae65" }, - "vim-exchange": { "branch": "master", "commit": "784d63083ad7d613aa96f00021cd0dfb126a781a" }, + "vim-exchange": { "branch": "master", "commit": "d6c1e9790bcb8df27c483a37167459bbebe0112e" }, "vim-numbertoggle": { "branch": "main", "commit": "df9b1fe616507340718716204ba7f434125bdf7a" }, "vim-pandoc-syntax": { "branch": "master", "commit": "16939cda184ff555938cc895cc62477c172997f9" }, "vim-spellsync": { "branch": "master", "commit": "3d6dd50de9c4d953cc16638112a6ae196df41463" }, From b47043d42b2c77a1abed144de7b9f2e061c42218 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Sat, 10 Feb 2024 13:40:18 +0100 Subject: [PATCH 05/29] papis: Fix mark opener setting name --- writing/.config/papis/config | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/writing/.config/papis/config b/writing/.config/papis/config index 2ef2eb3..edc64cf 100644 --- a/writing/.config/papis/config +++ b/writing/.config/papis/config @@ -5,7 +5,7 @@ local-config-file = .papis.config opentool = sioyek picktool = papis-tui -mark-opener = sioyek --page {mark[value]} +mark-opener-format = sioyek --page {mark[value]} file-browser = vifm # edit info.yaml as new papers are added From 044eedea32b87f4b84afc578e791710004cb236c Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Sat, 10 Feb 2024 13:41:30 +0100 Subject: [PATCH 06/29] neomutt: Add ics to calendar by printing it By invoking 'print' for ics files from neomutt we can simply add it to our local calendar directly from the interface. Neat little 'cheat' to provide custom functions for specific file types. --- office/.config/neomutt/mailcap | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/office/.config/neomutt/mailcap b/office/.config/neomutt/mailcap index 027ca80..384dcce 100644 --- a/office/.config/neomutt/mailcap +++ b/office/.config/neomutt/mailcap @@ -6,8 +6,8 @@ text/html; render-prettyhtml %s; nametemplate=%s.html; copiousoutput; text/plain; $EDITOR %s ; # show calendar invites -text/calendar; mutt-ics; copiousoutput -application/ics; mutt-ics; copiousoutput +text/calendar; mutt-ics; description=ics details; copiousoutput; print=khal import %s; needsterminal +application/ics; mutt-ics; description=ics details; copiousoutput; print=khal import %s; needsterminal # open images externally image/*; imv %s ; From 89ea7e9cf29d22adff729f7c36554e9ecfb41d7e Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Sat, 10 Feb 2024 14:07:07 +0100 Subject: [PATCH 07/29] nvim: Switch to mini operators plugin Removed vim-exchange which, while an amazing functionality, is also exactly replicated in mini.nvim (along with even more operators). Uses slightly different mapping - not `cx` anymore but `gx`. But this actually makes sense and fits in well with my other g-prefixed operators (`gc` for comment and `ga` for align). It is also the prefix for the other additional operators supplied by mini.operators: `gs` for sorting text, `gm` for multiplying, `gr` for replacing, `g=` for evaluating. --- nvim/.config/nvim/lua/plugins/config/mini.lua | 4 +++- nvim/.config/nvim/lua/plugins/editing.lua | 5 ----- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/nvim/.config/nvim/lua/plugins/config/mini.lua b/nvim/.config/nvim/lua/plugins/config/mini.lua index 6275595..a23508f 100644 --- a/nvim/.config/nvim/lua/plugins/config/mini.lua +++ b/nvim/.config/nvim/lua/plugins/config/mini.lua @@ -1,3 +1,4 @@ +-- automatic callback to invoke 'mini.base16' when colorscheme file is changed local colorsfile = vim.fn.stdpath("state") .. "/colorscheme.lua" local function source_colors() if vim.fn.filereadable(colorsfile) == 1 then @@ -33,7 +34,8 @@ require("mini.indentscope").setup({ }) require("mini.map").setup() -require("mini.move").setup() -- has not hit stable yet +require("mini.move").setup() +require("mini.operators").setup() require("mini.pairs").setup() require("mini.trailspace").setup() diff --git a/nvim/.config/nvim/lua/plugins/editing.lua b/nvim/.config/nvim/lua/plugins/editing.lua index 67e08ed..6c41211 100644 --- a/nvim/.config/nvim/lua/plugins/editing.lua +++ b/nvim/.config/nvim/lua/plugins/editing.lua @@ -1,9 +1,4 @@ return { - -- adds exchange operator with cx. common use: cxiw . on 2 words to switch - { - "tommcdo/vim-exchange", - event = "InsertEnter", - }, -- Align tables and other alignable things { "junegunn/vim-easy-align", From 1d70d0c64935a0908ec1ef6d04abbf9f7bba1443 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Sat, 10 Feb 2024 14:14:17 +0100 Subject: [PATCH 08/29] nvim: Switch starter screen recent files order First show recent files of the current directory, then follow up with general recent files. --- nvim/.config/nvim/lua/plugins/config/mini.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/nvim/.config/nvim/lua/plugins/config/mini.lua b/nvim/.config/nvim/lua/plugins/config/mini.lua index a23508f..523d94e 100644 --- a/nvim/.config/nvim/lua/plugins/config/mini.lua +++ b/nvim/.config/nvim/lua/plugins/config/mini.lua @@ -44,9 +44,10 @@ starter.setup({ evaluate_single = true, items = { starter.sections.builtin_actions(), - starter.sections.recent_files(10, false), starter.sections.recent_files(10, true), + starter.sections.recent_files(10, false), -- Use this if you set up 'mini.sessions' + -- starter.sections.sessions(), starter.sections.telescope(), }, content_hooks = { From 1d0f47f2e87d7a2b5b97901b32e901fcd21993bd Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Thu, 15 Feb 2024 08:47:50 +0100 Subject: [PATCH 09/29] flavours: Check for nvim plugin existence in template Checks that mini.base16 plugin exists before executing its setup, and checks that lualine exists before executing its setup. --- .../templates/nvim/templates/default.mustache | 52 +++++++++++-------- 1 file changed, 31 insertions(+), 21 deletions(-) diff --git a/desktop/.config/flavours/templates/nvim/templates/default.mustache b/desktop/.config/flavours/templates/nvim/templates/default.mustache index c2cd8de..2453834 100644 --- a/desktop/.config/flavours/templates/nvim/templates/default.mustache +++ b/desktop/.config/flavours/templates/nvim/templates/default.mustache @@ -7,26 +7,36 @@ -- by RRethy (https://github.com/RRethy/nvim-base16) -- {{scheme-name}} scheme by {{scheme-author}} -require('mini.base16').setup({ - palette = { - base00 = '#{{base00-hex}}', - base01 = '#{{base01-hex}}', - base02 = '#{{base02-hex}}', - base03 = '#{{base03-hex}}', - base04 = '#{{base04-hex}}', - base05 = '#{{base05-hex}}', - base06 = '#{{base06-hex}}', - base07 = '#{{base07-hex}}', - base08 = '#{{base08-hex}}', - base09 = '#{{base09-hex}}', - base0A = '#{{base0A-hex}}', - base0B = '#{{base0B-hex}}', - base0C = '#{{base0C-hex}}', - base0D = '#{{base0D-hex}}', - base0E = '#{{base0E-hex}}', - base0F = '#{{base0F-hex}}' - }, -}) -require('lualine').setup() +local function exists(plugin) + local status, lib = pcall(require, plugin) + if(status) then return true end + return false +end + +if exists("mini.base16") then + require('mini.base16').setup({ + palette = { + base00 = '#{{base00-hex}}', + base01 = '#{{base01-hex}}', + base02 = '#{{base02-hex}}', + base03 = '#{{base03-hex}}', + base04 = '#{{base04-hex}}', + base05 = '#{{base05-hex}}', + base06 = '#{{base06-hex}}', + base07 = '#{{base07-hex}}', + base08 = '#{{base08-hex}}', + base09 = '#{{base09-hex}}', + base0A = '#{{base0A-hex}}', + base0B = '#{{base0B-hex}}', + base0C = '#{{base0C-hex}}', + base0D = '#{{base0D-hex}}', + base0E = '#{{base0E-hex}}', + base0F = '#{{base0F-hex}}' + }, + }) +end +if exists("lualine") then + require("lualine").setup() +end -- vim: filetype=lua From 9fb1f958e61ce2b628a739ac5ea87e2b714996a8 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Thu, 15 Feb 2024 08:52:14 +0100 Subject: [PATCH 10/29] nvim: Remove fixed term sigwinch timer --- nvim/.config/nvim/lua/core/autocmds.lua | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/nvim/.config/nvim/lua/core/autocmds.lua b/nvim/.config/nvim/lua/core/autocmds.lua index 6f72b9e..cfd2303 100644 --- a/nvim/.config/nvim/lua/core/autocmds.lua +++ b/nvim/.config/nvim/lua/core/autocmds.lua @@ -18,18 +18,6 @@ vim.api.nvim_create_autocmd({ "BufNewFile", "BufRead" }, { group = vim.api.nvim_create_augroup("passnoleak", { clear = true }), }) --- fixing neovim opening up at same moment as alacritty (see https://github.com/neovim/neovim/issues/11330) -vim.api.nvim_create_autocmd({ "VimEnter" }, { - callback = function() - local pid, WINCH = vim.fn.getpid(), vim.loop.constants.SIGWINCH - vim.defer_fn(function() - vim.loop.kill(pid, WINCH) - end, 20) - end, - desc = "Fix neovim sizing issues if opening same time as alacritty", - group = vim.api.nvim_create_augroup("alacritty_fixsize", { clear = true }), -}) - -- remove line numbers from terminal buffers vim.api.nvim_create_autocmd({ "TermOpen" }, { desc = "Hide buffer numbers for terminals", From 7c37baa565219719033066bb87cc7c9453205038 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Thu, 15 Feb 2024 08:53:55 +0100 Subject: [PATCH 11/29] nvim: Move toggleterm out of core plugins Toggleterm, as nice as it is, is not one of my core dependencies. I do not 'need' toggleterm on every nvim installation I have. Instead, it can go into ui-related plugins since that is what it does, extend nvim's UI functionality with new terminal dropdowns/floats. --- .../nvim/lua/plugins/config/toggleterm.lua | 85 --------------- nvim/.config/nvim/lua/plugins/core.lua | 14 --- nvim/.config/nvim/lua/plugins/ui.lua | 103 +++++++++++++++++- 3 files changed, 102 insertions(+), 100 deletions(-) delete mode 100644 nvim/.config/nvim/lua/plugins/config/toggleterm.lua diff --git a/nvim/.config/nvim/lua/plugins/config/toggleterm.lua b/nvim/.config/nvim/lua/plugins/config/toggleterm.lua deleted file mode 100644 index 6bbd56d..0000000 --- a/nvim/.config/nvim/lua/plugins/config/toggleterm.lua +++ /dev/null @@ -1,85 +0,0 @@ -require("toggleterm").setup({ - open_mapping = [[=]], - insert_mappings = false, -- don't map the key in insert mode - terminal_mappings = false, -}) - -local Terminal = require("toggleterm.terminal").Terminal - --- need to disable indentlines since they obscure first line of terminal -if require("util").is_available("mini.nvim") then - vim.api.nvim_create_autocmd({ "TermOpen" }, { - pattern = "*", - callback = function() - vim.b.miniindentscope_disable = true - end, - }) -end - -local function custom_term_set_toggle_key(term) - vim.keymap.set("t", "", function() - term:toggle() - end, { silent = true, buffer = true }) -end - --- create python window -local function get_python_cmd() - if vim.fn.executable("ptipython") then - return "ptipython" - end - if vim.fn.executable("ipython") then - return "ipython" - end - if vim.fn.executable("ptpython") then - return "ptpython" - end - if vim.fn.executable("python") then - return "python" - end -end -local terms = { - lazygit = Terminal:new({ - cmd = "lazygit", - hidden = true, - direction = "float", - float_opts = { border = "curved" }, - on_open = custom_term_set_toggle_key, - }), - python = Terminal:new({ - cmd = get_python_cmd(), - hidden = true, - direction = "float", - float_opts = { border = "curved" }, - on_open = custom_term_set_toggle_key, - }), -} --- create a lazygit window with the lazygit command -local function toggle_custom_term(term, bang, vertsize) - vertsize = vertsize or vim.o.columns * 0.4 - if not bang then - term.direction = "float" - term:toggle() - else - term.direction = "vertical" - term:resize(vertsize) - term:toggle() - end -end - -local function _Pythonterm_toggle(opts) - toggle_custom_term(terms.python, opts.bang) -end -local function _Lazygit_toggle(opts) - toggle_custom_term(terms.lazygit, opts.bang, vim.o.columns * 0.6) -end - -vim.api.nvim_create_user_command( - "Lazygit", - _Lazygit_toggle, - { desc = "Toggle floating Lazygit terminal", bang = true } -) -vim.api.nvim_create_user_command( - "Pythonterm", - _Pythonterm_toggle, - { desc = "Toggle floating Python terminal", bang = true } -) diff --git a/nvim/.config/nvim/lua/plugins/core.lua b/nvim/.config/nvim/lua/plugins/core.lua index cbcbb23..cbdb644 100644 --- a/nvim/.config/nvim/lua/plugins/core.lua +++ b/nvim/.config/nvim/lua/plugins/core.lua @@ -73,20 +73,6 @@ return { }, }, }, - -- simpler, programmable and multiple terminal toggling for nvim - { - "akinsho/nvim-toggleterm.lua", - config = function() - require("plugins.config.toggleterm") - end, - cmd = { "ToggleTerm", "TermExec", "Lazygit", "Pythonterm" }, - keys = { - { "sg", ":Lazygit" }, - { "sG", ":Lazygit!" }, - { "sp", ":Pythonterm" }, - { "sP", ":Pythonterm!" }, - }, - }, -- try to avoid putting files in util buffers, e.g. filetree, aerial, undotree, .. { "stevearc/stickybuf.nvim", config = true }, -- make it a little less painful to open really big (>2mb) files by disabling features diff --git a/nvim/.config/nvim/lua/plugins/ui.lua b/nvim/.config/nvim/lua/plugins/ui.lua index 90ac1ee..b624b8c 100644 --- a/nvim/.config/nvim/lua/plugins/ui.lua +++ b/nvim/.config/nvim/lua/plugins/ui.lua @@ -45,7 +45,7 @@ return { override_vim_notify = true, }, }, - event = "VimEnter", + event = { "VeryLazy" }, }, -- make all vim.ui interfaces prettyy { "stevearc/dressing.nvim", config = true, event = "VeryLazy" }, @@ -111,4 +111,105 @@ return { }, }, }, + -- simpler, programmable and multiple terminal toggling for nvim + { + "akinsho/nvim-toggleterm.lua", + config = function() + require("toggleterm").setup({ + open_mapping = [[=]], + insert_mappings = false, -- don't map the key in insert mode + terminal_mappings = false, + }) + + local Terminal = require("toggleterm.terminal").Terminal + + -- need to disable indentlines since they obscure first line of terminal + if require("util").is_available("mini.nvim") then + vim.api.nvim_create_autocmd({ "TermOpen" }, { + pattern = "*", + callback = function() + vim.b.miniindentscope_disable = true + end, + }) + end + + local function custom_term_set_toggle_key(term) + vim.keymap.set("t", "", function() + term:toggle() + end, { silent = true, buffer = true }) + end + + -- create python window + local function get_python_cmd() + if vim.fn.executable("py") then + return "py" + end + if vim.fn.executable("ptipython") then + return "ptipython" + end + if vim.fn.executable("ipython") then + return "ipython" + end + if vim.fn.executable("ptpython") then + return "ptpython" + end + if vim.fn.executable("python") then + return "python" + end + end + local terms = { + lazygit = Terminal:new({ + cmd = "lazygit", + hidden = true, + direction = "float", + float_opts = { border = "curved" }, + on_open = custom_term_set_toggle_key, + }), + python = Terminal:new({ + cmd = get_python_cmd(), + hidden = true, + direction = "float", + float_opts = { border = "curved" }, + on_open = custom_term_set_toggle_key, + }), + } + -- create a lazygit window with the lazygit command + local function toggle_custom_term(term, bang, vertsize) + vertsize = vertsize or vim.o.columns * 0.4 + if not bang then + term.direction = "float" + term:toggle() + else + term.direction = "vertical" + term:resize(vertsize) + term:toggle() + end + end + + local function _Pythonterm_toggle(opts) + toggle_custom_term(terms.python, opts.bang) + end + local function _Lazygit_toggle(opts) + toggle_custom_term(terms.lazygit, opts.bang, vim.o.columns * 0.6) + end + + vim.api.nvim_create_user_command( + "Lazygit", + _Lazygit_toggle, + { desc = "Toggle floating Lazygit terminal", bang = true } + ) + vim.api.nvim_create_user_command( + "Pythonterm", + _Pythonterm_toggle, + { desc = "Toggle floating Python terminal", bang = true } + ) + end, + cmd = { "ToggleTerm", "TermExec", "Lazygit", "Pythonterm" }, + keys = { + { "sg", ":Lazygit", desc = "git floating" }, + { "sG", ":Lazygit!", desc = "git buffer" }, + { "sp", ":Pythonterm", desc = "python floating" }, + { "sP", ":Pythonterm!", desc = "python buffer" }, + }, + }, } From 0c7ad097893b79e44de7bffcf7aebe34376759be Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Thu, 15 Feb 2024 09:02:39 +0100 Subject: [PATCH 12/29] nvim: Move mini configuration into core plugin file Since I would like to keep my plugin configurations as modular as possible I think it is a good first step to move the mini configuration directly into the core plugin file where mini is loaded. Since this is the plugin spec I want to take to basically any nvim installation I have, having it in a single file makes it much easier to be portable. --- nvim/.config/nvim/lua/plugins/config/mini.lua | 79 ------------------- nvim/.config/nvim/lua/plugins/core.lua | 78 +++++++++++++++++- 2 files changed, 77 insertions(+), 80 deletions(-) delete mode 100644 nvim/.config/nvim/lua/plugins/config/mini.lua diff --git a/nvim/.config/nvim/lua/plugins/config/mini.lua b/nvim/.config/nvim/lua/plugins/config/mini.lua deleted file mode 100644 index 523d94e..0000000 --- a/nvim/.config/nvim/lua/plugins/config/mini.lua +++ /dev/null @@ -1,79 +0,0 @@ --- automatic callback to invoke 'mini.base16' when colorscheme file is changed -local colorsfile = vim.fn.stdpath("state") .. "/colorscheme.lua" -local function source_colors() - if vim.fn.filereadable(colorsfile) == 1 then - vim.cmd("source " .. colorsfile) - end -end --- set on startup -source_colors() - --- continuously watch colors file for changes -local fwatch = require("fwatch") -fwatch.watch(colorsfile, { - on_event = vim.schedule_wrap(function() - source_colors() - end), -}) - -require("mini.ai").setup() -require("mini.comment").setup({ - hooks = { - pre = function() - require("ts_context_commentstring.internal").update_commentstring() - end, - }, -}) -require("mini.cursorword").setup({ delay = 500 }) -require("mini.fuzzy").setup() - -require("mini.indentscope").setup({ - symbol = "│", - draw = { animation = require("mini.indentscope").gen_animation.none() }, - options = { indent_at_cursor = false }, -}) - -require("mini.map").setup() -require("mini.move").setup() -require("mini.operators").setup() -require("mini.pairs").setup() -require("mini.trailspace").setup() - -local starter = require("mini.starter") -starter.setup({ - evaluate_single = true, - items = { - starter.sections.builtin_actions(), - starter.sections.recent_files(10, true), - starter.sections.recent_files(10, false), - -- Use this if you set up 'mini.sessions' - -- starter.sections.sessions(), - starter.sections.telescope(), - }, - content_hooks = { - starter.gen_hook.adding_bullet(), - starter.gen_hook.padding(3, 2), - starter.gen_hook.aligning("center", "center"), - }, -}) - -vim.api.nvim_set_hl(0, "MiniCursorword", { bold = true }) - -require("mini.bracketed").setup({ - { - buffer = { suffix = "b", options = {} }, - comment = { suffix = "c", options = {} }, - conflict = { suffix = "", options = {} }, - diagnostic = { suffix = "d", options = {} }, - file = { suffix = "f", options = {} }, - indent = { suffix = "", options = {} }, -- disable since we use indentscope above - jump = { suffix = "j", options = {} }, - location = { suffix = "l", options = {} }, - oldfile = { suffix = "o", options = {} }, - quickfix = { suffix = "q", options = {} }, - treesitter = { suffix = "t", options = {} }, - undo = { suffix = "", options = {} }, -- disable since I don't need it - window = { suffix = "w", options = {} }, - yank = { suffix = "y", options = {} }, - }, -}) diff --git a/nvim/.config/nvim/lua/plugins/core.lua b/nvim/.config/nvim/lua/plugins/core.lua index cbdb644..cde0dcd 100644 --- a/nvim/.config/nvim/lua/plugins/core.lua +++ b/nvim/.config/nvim/lua/plugins/core.lua @@ -59,7 +59,83 @@ return { version = "*", dependencies = { "rktjmp/fwatch.nvim" }, config = function() - require("plugins.config.mini") + -- automatic callback to invoke 'mini.base16' when colorscheme file is changed + local colorsfile = vim.fn.stdpath("state") .. "/colorscheme.lua" + local function source_colors() + if vim.fn.filereadable(colorsfile) == 1 then + vim.cmd("source " .. colorsfile) + end + end + -- set on startup + source_colors() + -- continuously watch colors file for changes + local fwatch = require("fwatch") + fwatch.watch(colorsfile, { + on_event = vim.schedule_wrap(function() + source_colors() + end), + }) + + require("mini.ai").setup() + require("mini.comment").setup({ + hooks = { + pre = function() + -- use treesitter commentstring functionality if it's installed + if require("util").is_available("ts_context_commentstring") then + require("ts_context_commentstring.internal").update_commentstring() + end + end, + }, + }) + require("mini.cursorword").setup({ delay = 500 }) + vim.api.nvim_set_hl(0, "MiniCursorword", { bold = true, underline = false }) + vim.api.nvim_set_hl(0, "MiniCursorwordCurrent", { bold = true, underline = false }) + require("mini.fuzzy").setup() + require("mini.indentscope").setup({ + symbol = "│", + draw = { animation = require("mini.indentscope").gen_animation.none() }, + options = { indent_at_cursor = false }, + }) + require("mini.map").setup() + require("mini.move").setup() + require("mini.operators").setup() + require("mini.pairs").setup() + require("mini.trailspace").setup() + local starter = require("mini.starter") + starter.setup({ + evaluate_single = true, + items = { + starter.sections.builtin_actions(), + starter.sections.recent_files(10, true), + starter.sections.recent_files(10, false), + -- Use this if you set up 'mini.sessions' + -- starter.sections.sessions(), + starter.sections.telescope(), + }, + content_hooks = { + starter.gen_hook.adding_bullet(), + starter.gen_hook.padding(3, 2), + starter.gen_hook.aligning("center", "center"), + }, + }) + require("mini.bracketed").setup({ + { + buffer = { suffix = "b", options = {} }, + comment = { suffix = "c", options = {} }, + conflict = { suffix = "", options = {} }, + diagnostic = { suffix = "d", options = {} }, + file = { suffix = "f", options = {} }, + indent = { suffix = "", options = {} }, -- disable since we use indentscope above + jump = { suffix = "j", options = {} }, + location = { suffix = "l", options = {} }, + oldfile = { suffix = "o", options = {} }, + quickfix = { suffix = "q", options = {} }, + treesitter = { suffix = "t", options = {} }, + undo = { suffix = "", options = {} }, -- disable since I don't need it + window = { suffix = "w", options = {} }, + yank = { suffix = "y", options = {} }, + }, + }) end, event = "VimEnter", -- need to load pretty soon for Starter screen keys = { From ab123a4c36bb5621d34853b1d7aba7303fb1acbc Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Fri, 16 Feb 2024 11:01:41 +0100 Subject: [PATCH 13/29] wezterm: Allow toggling tab bar display Tab display can be toggled on or off with `Ctrl+Shift+T`. The toggling takes place per-window and not globally, so we can have a wezterm terminal on desktop 1 with a tabbar and on desktop 2 without. Opening a new terminal always defaults to an enabled tab bar. --- terminal/.config/wezterm/events.lua | 16 ++++++++++++++-- terminal/.config/wezterm/maps.lua | 1 + terminal/.config/wezterm/wezterm.lua | 1 + 3 files changed, 16 insertions(+), 2 deletions(-) diff --git a/terminal/.config/wezterm/events.lua b/terminal/.config/wezterm/events.lua index 853aed8..936a9b6 100644 --- a/terminal/.config/wezterm/events.lua +++ b/terminal/.config/wezterm/events.lua @@ -67,15 +67,27 @@ local function setup() wezterm.log_info("toggling the leader") local overrides = window:get_config_overrides() or {} if not overrides.leader then - wezterm.log_info("leader wasn't set") + wezterm.log_info("enabling leader key") overrides.leader = { key = "s", mods = "SUPER" } else - wezterm.log_info("leader was set") + wezterm.log_info("disabling leader key") overrides.leader = nil end window:set_config_overrides(overrides) end) + + wezterm.on("toggle-tabbar", function(window, _) + local overrides = window:get_config_overrides() or {} + if overrides.enable_tab_bar == false then + wezterm.log_info("showing tab bar") + overrides.enable_tab_bar = true + else + wezterm.log_info("hiding tab bar") + overrides.enable_tab_bar = false + end + window:set_config_overrides(overrides) + end) end return { setup = setup } diff --git a/terminal/.config/wezterm/maps.lua b/terminal/.config/wezterm/maps.lua index 74cc6bd..40e1b43 100644 --- a/terminal/.config/wezterm/maps.lua +++ b/terminal/.config/wezterm/maps.lua @@ -100,6 +100,7 @@ local keys = { action = act.EmitEvent("ActivatePaneDirection-Right"), }, { key = "a", mods = "CTRL|ALT", action = act.EmitEvent("toggle-leader") }, + { key = "T", mods = "CTRL", action = act.EmitEvent("toggle-tabbar") }, } -- Leader + number to activate that tab for i = 1, 8 do diff --git a/terminal/.config/wezterm/wezterm.lua b/terminal/.config/wezterm/wezterm.lua index 57db5b8..01ba9a5 100644 --- a/terminal/.config/wezterm/wezterm.lua +++ b/terminal/.config/wezterm/wezterm.lua @@ -25,6 +25,7 @@ end local settings = { enable_wayland = true, + enable_tab_bar = true, hide_tab_bar_if_only_one_tab = true, use_fancy_tab_bar = false, tab_bar_at_bottom = true, From 4c5d18d7e4c2c22ec6566f2335266aaf484578e1 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Sun, 18 Feb 2024 10:24:46 +0100 Subject: [PATCH 14/29] nvim: Change lualine design Slightly adapt lualine to not have arrow section/component dividers, but simple slanted lines. Gets rid of a tiny bit of noise while still clearly subdividing the sections for me which I need. Also, removed displaying the hostname. I know which host I am on generally, and rarely make use of it so it's just unnecessary info for me. --- nvim/.config/nvim/lua/plugins/ui.lua | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/nvim/.config/nvim/lua/plugins/ui.lua b/nvim/.config/nvim/lua/plugins/ui.lua index b624b8c..479e256 100644 --- a/nvim/.config/nvim/lua/plugins/ui.lua +++ b/nvim/.config/nvim/lua/plugins/ui.lua @@ -7,8 +7,8 @@ return { options = { icons_enabled = true, theme = "auto", - component_separators = { left = "", right = "" }, - section_separators = { left = "", right = "" }, + component_separators = { left = "", right = "" }, + section_separators = { left = "", right = "" }, disabled_filetypes = {}, always_divide_middle = true, }, @@ -17,8 +17,8 @@ return { lualine_b = { "branch", "diff", "diagnostics" }, lualine_c = { "filename" }, lualine_x = { "encoding", "fileformat", "filetype" }, - lualine_y = { "progress", "location" }, - lualine_z = { "hostname" }, + lualine_y = { "progress" }, + lualine_z = { "location" }, }, inactive_sections = { lualine_a = {}, @@ -51,7 +51,7 @@ return { { "stevearc/dressing.nvim", config = true, event = "VeryLazy" }, -- numbers to absolute for all buffers but the current which is relative - { "jeffkreeftmeijer/vim-numbertoggle", event = "BufEnter" }, + { "jeffkreeftmeijer/vim-numbertoggle", event = "InsertEnter" }, -- auto-hiding colorcolumn { "m4xshen/smartcolumn.nvim", From 572f7b29a40ead20fc1ae6406a2a5edc843aebca Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Sun, 18 Feb 2024 11:14:37 +0100 Subject: [PATCH 15/29] nvim: Switch lightspeed to flash Flash.nvim provides a very tasty remote editing functionality which lightspeed does not. Otherwise it behaves *mostly* the same. For now, I have the flash search label functionality activated (default) but if it is annoying I will turn it off (It injects labels into the normal neovim search. So if you search a word and want to go directly there, you just press the label key as part of the search and it jumps there. This might be problematic if I quickly type something that does not exist but it picks up a non-existent letter as label instead.) Otherwise, the remote editing functionality is activated by r