From 82f2f1ad851a3b0f0b5cdb305e4fffcbf81134b4 Mon Sep 17 00:00:00 2001 From: hektor Date: Tue, 9 Jun 2026 19:26:54 +0200 Subject: [PATCH] refactor(nvim): migrate to nix-only 'nvim' --- dots/.config/nvim/flake.nix | 1 + dots/.config/nvim/init.lua | 2 - .../nvim/lua/nixCatsUtils/catPacker.lua | 53 ------------------- dots/.config/nvim/lua/paq-setup.lua | 47 ---------------- dots/.config/nvim/lua/plug.lua | 35 ------------ 5 files changed, 1 insertion(+), 137 deletions(-) delete mode 100644 dots/.config/nvim/lua/nixCatsUtils/catPacker.lua delete mode 100644 dots/.config/nvim/lua/paq-setup.lua delete mode 100644 dots/.config/nvim/lua/plug.lua diff --git a/dots/.config/nvim/flake.nix b/dots/.config/nvim/flake.nix index 193af2e4..4511b0f9 100644 --- a/dots/.config/nvim/flake.nix +++ b/dots/.config/nvim/flake.nix @@ -174,6 +174,7 @@ nvim-treesitter-textobjects # nvim-treesitter-context nvim-ts-context-commentstring + # theHamsta/crazy-node-movement treesj sniprun gitsigns-nvim diff --git a/dots/.config/nvim/init.lua b/dots/.config/nvim/init.lua index 37d0fadf..434df4d1 100644 --- a/dots/.config/nvim/init.lua +++ b/dots/.config/nvim/init.lua @@ -8,11 +8,9 @@ require("cursor") require("fold") require("netrw") require("ftdetect") -require("plug") require("pandoc") require("keymaps") require("highlight") -require("paq-setup") require("statusline") require("diagnostic") require("utils") diff --git a/dots/.config/nvim/lua/nixCatsUtils/catPacker.lua b/dots/.config/nvim/lua/nixCatsUtils/catPacker.lua deleted file mode 100644 index bc28ccb6..00000000 --- a/dots/.config/nvim/lua/nixCatsUtils/catPacker.lua +++ /dev/null @@ -1,53 +0,0 @@ --- Source: https://github.com/BirdeeHub/nixCats-nvim/blob/main/templates/example/lua/nixCatsUtils/catPacker.lua ---[[ - This directory is the luaUtils template. - You can choose what things from it that you would like to use. - And then delete the rest. - Everything in this directory is optional. ---]] - -local M = {} --- NOTE: This function is for defining a paq.nvim fallback method of downloading plugins --- when nixCats was not used to install your config. --- If you only ever load your config using nixCats, you don't need this file. - --- it literally just only runs it when not on nixCats --- all neovim package managers that use the regular plugin loading scheme --- can be used this way, just do whatever the plugin manager needs to put it in the --- opt directory for lazy loading, and add the build steps so that when theres no nix the steps are ran -function M.setup(v) - if not vim.g[ [[nixCats-special-rtp-entry-nixCats]] ] then - local function clone_paq() - local path = vim.fn.stdpath("data") .. "/site/pack/paqs/start/paq-nvim" - local is_installed = vim.fn.empty(vim.fn.glob(path)) == 0 - if not is_installed then - vim.fn.system({ "git", "clone", "--depth=1", "https://github.com/savq/paq-nvim.git", path }) - return true - end - end - local function bootstrap_paq(packages) - local first_install = clone_paq() - vim.cmd.packadd("paq-nvim") - local paq = require("paq") - if first_install then - vim.notify("Installing plugins... If prompted, hit Enter to continue.") - end - paq(packages) - paq.install() - end - - vim.api.nvim_create_autocmd("VimEnter", { - once = true, - callback = function() - local pkgs_count = #require("paq").query("to_install") - if pkgs_count < 1 then - return - end - vim.notify(string.format("There are %d to install", pkgs_count)) - end, - }) - - bootstrap_paq(vim.list_extend({ "savq/paq-nvim" }, v)) - end -end -return M diff --git a/dots/.config/nvim/lua/paq-setup.lua b/dots/.config/nvim/lua/paq-setup.lua deleted file mode 100644 index 5b383caf..00000000 --- a/dots/.config/nvim/lua/paq-setup.lua +++ /dev/null @@ -1,47 +0,0 @@ -require("nixCatsUtils.catPacker").setup({ - { "savq/paq-nvim" }, - { "jinh0/eyeliner.nvim" }, - { "ibhagwan/fzf-lua" }, - { "barreiroleo/ltex_extra.nvim" }, - { "neovim/nvim-lspconfig" }, - { "https://git.sr.ht/~whynothugo/lsp_lines.nvim" }, - { "linrongbin16/lsp-progress.nvim" }, - { "folke/neodev.nvim" }, -- Nvim - { "b0o/schemastore.nvim" }, -- JSON Schemas - { "mfussenegger/nvim-lint" }, - { "stevearc/conform.nvim" }, - { "L3MON4D3/LuaSnip" }, - { "saadparwaiz1/cmp_luasnip" }, - { "hrsh7th/nvim-cmp" }, - { "hrsh7th/cmp-nvim-lsp" }, - { "hrsh7th/cmp-buffer" }, - { "hrsh7th/cmp-path" }, - { "nvim-lua/plenary.nvim" }, - { "MunifTanjim/nui.nvim" }, - { "folke/trouble.nvim" }, - { "rktjmp/shipwright.nvim" }, -- For building themes based on lush (e.g. terminal) - { "rktjmp/lush.nvim" }, - { "mcchrish/zenbones.nvim" }, -- Zenbones themes (contains zenwritten) - { "theHamsta/crazy-node-movement" }, - { "nvim-treesitter/nvim-treesitter", build = ":TSUpdate" }, - { "nvim-treesitter/nvim-treesitter-textobjects" }, - -- { "nvim-treesitter/nvim-treesitter-context" }, - { "JoosepAlviste/nvim-ts-context-commentstring" }, -- commentstring based on cursor position (e.g. for Svelte) - { "Wansmer/treesj" }, - { "michaelb/sniprun", build = "sh install.sh" }, - { "lewis6991/gitsigns.nvim" }, - { "brenoprata10/nvim-highlight-colors" }, - { "razak17/tailwind-fold.nvim" }, - { "rmagatti/auto-session" }, - { "kndndrj/nvim-dbee" }, - { "3rd/image.nvim", build = false }, - { "polarmutex/beancount.nvim" }, - { "jamesblckwell/nvimkit.nvim" }, - { 'olimorris/codecompanion.nvim' }, - { "ravitemer/mcphub.nvim", build = "pnpm install -g mcp-hub@latest" }, - { "zbirenbaum/copilot.lua" }, - { "zbirenbaum/copilot-cmp" }, - { "qvalentin/helm-ls.nvim", ft = "helm" }, - { "mikesmithgh/kitty-scrollback.nvim" }, - { "greggh/claude-code.nvim" }, -}) diff --git a/dots/.config/nvim/lua/plug.lua b/dots/.config/nvim/lua/plug.lua deleted file mode 100644 index 142768fd..00000000 --- a/dots/.config/nvim/lua/plug.lua +++ /dev/null @@ -1,35 +0,0 @@ -if not vim.g[ [[nixCats-special-rtp-entry-nixCats]] ] then - local vim = vim - local Plug = vim.fn["plug#"] - - vim.call("plug#begin") - - Plug("machakann/vim-sandwich") - Plug("Shougo/context_filetype.vim") - Plug("editorconfig/editorconfig-vim") - Plug("honza/vim-snippets") - Plug("chrisbra/unicode.vim") - Plug("ap/vim-css-color") - -- Jupyter - Plug("quarto-dev/quarto-vim") - -- LaTeX - Plug("lervag/vimtex") - -- Wiki - Plug("lervag/wiki.vim") - -- Markdown - Plug("vim-pandoc/vim-pandoc") - Plug("vim-pandoc/vim-pandoc-syntax") - Plug("ferrine/md-img-paste.vim") - -- TidalCycles - Plug("supercollider/scvim") - Plug("tidalcycles/vim-tidal") - -- GLSL - Plug("tikhomirov/vim-glsl") - Plug("timtro/glslView-nvim") - -- Jupyter notebooks - Plug("goerz/jupytext.vim") - -- OpenSCAD - Plug("sirtaj/vim-openscad") - - vim.call("plug#end") -end