From e5918cc142e4c28885738d8817747c2ff8c7faaf Mon Sep 17 00:00:00 2001 From: teesh3rt Date: Fri, 6 Feb 2026 18:15:49 +0200 Subject: [PATCH] feat: ngl, lazyvim was better. --- flake.lock | 158 +++++++++++++--------------------------- flake.nix | 4 +- modules/base/neovim.nix | 79 +++++++++----------- 3 files changed, 87 insertions(+), 154 deletions(-) diff --git a/flake.lock b/flake.lock index c4f5008..b113020 100644 --- a/flake.lock +++ b/flake.lock @@ -125,22 +125,6 @@ "type": "github" } }, - "flake-compat": { - "flake": false, - "locked": { - "lastModified": 1751685974, - "narHash": "sha256-NKw96t+BgHIYzHUjkTK95FqYRVKB8DHpVhefWSz/kTw=", - "ref": "refs/heads/main", - "rev": "549f2762aebeff29a2e5ece7a7dc0f955281a1d1", - "revCount": 92, - "type": "git", - "url": "https://git.lix.systems/lix-project/flake-compat.git" - }, - "original": { - "type": "git", - "url": "https://git.lix.systems/lix-project/flake-compat.git" - } - }, "flake-parts": { "inputs": { "nixpkgs-lib": [ @@ -162,27 +146,6 @@ } }, "flake-parts_2": { - "inputs": { - "nixpkgs-lib": [ - "nvf", - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1768135262, - "narHash": "sha256-PVvu7OqHBGWN16zSi6tEmPwwHQ4rLPU9Plvs8/1TUBY=", - "owner": "hercules-ci", - "repo": "flake-parts", - "rev": "80daad04eddbbf5a4d883996a73f3f542fa437ac", - "type": "github" - }, - "original": { - "owner": "hercules-ci", - "repo": "flake-parts", - "type": "github" - } - }, - "flake-parts_3": { "inputs": { "nixpkgs-lib": [ "stylix", @@ -218,6 +181,24 @@ "type": "github" } }, + "flake-utils_2": { + "inputs": { + "systems": "systems" + }, + "locked": { + "lastModified": 1731533236, + "narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "11707dc2f618dd54ca8739b309ec4fc024de578b", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, "fromYaml": { "flake": false, "locked": { @@ -289,40 +270,22 @@ "type": "github" } }, - "mnw": { - "locked": { - "lastModified": 1769981889, - "narHash": "sha256-ndI7AxL/6auelkLHngdUGVImBiHkG8w2N2fOTKZKn4k=", - "owner": "Gerg-L", - "repo": "mnw", - "rev": "332fed8f43b77149c582f1782683d6aeee1f07cf", - "type": "github" - }, - "original": { - "owner": "Gerg-L", - "repo": "mnw", - "type": "github" - } - }, - "ndg": { + "lazyvim": { "inputs": { - "nixpkgs": [ - "nvf", - "nixpkgs" - ] + "flake-utils": "flake-utils_2", + "nixpkgs": "nixpkgs_2" }, "locked": { - "lastModified": 1768214250, - "narHash": "sha256-hnBZDQWUxJV3KbtvyGW5BKLO/fAwydrxm5WHCWMQTbw=", - "owner": "feel-co", - "repo": "ndg", - "rev": "a6bd3c1ce2668d096e4fdaaa03ad7f03ba1fbca8", + "lastModified": 1770068987, + "narHash": "sha256-NZy5S0xkntbfW3SfluZg5hbDzRw4eFBsFm9knXzH8Eo=", + "owner": "pfassina", + "repo": "lazyvim-nix", + "rev": "a88c488cfd96e1d4274d34d2e35ddbe99dbe5757", "type": "github" }, "original": { - "owner": "feel-co", - "ref": "refs/tags/v2.6.0", - "repo": "ndg", + "owner": "pfassina", + "repo": "lazyvim-nix", "type": "github" } }, @@ -330,7 +293,7 @@ "inputs": { "niri-stable": "niri-stable", "niri-unstable": "niri-unstable", - "nixpkgs": "nixpkgs_2", + "nixpkgs": "nixpkgs_3", "nixpkgs-stable": "nixpkgs-stable", "xwayland-satellite-stable": "xwayland-satellite-stable", "xwayland-satellite-unstable": "xwayland-satellite-unstable" @@ -414,6 +377,22 @@ } }, "nixpkgs_2": { + "locked": { + "lastModified": 1752480373, + "narHash": "sha256-JHQbm+OcGp32wAsXTE/FLYGNpb+4GLi5oTvCxwSoBOA=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "62e0f05ede1da0d54515d4ea8ce9c733f12d9f08", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_3": { "locked": { "lastModified": 1770115704, "narHash": "sha256-KHFT9UWOF2yRPlAnSXQJh6uVcgNcWlFqqiAZ7OVlHNc=", @@ -429,7 +408,7 @@ "type": "github" } }, - "nixpkgs_3": { + "nixpkgs_4": { "locked": { "lastModified": 1770136044, "narHash": "sha256-tlFqNG/uzz2++aAmn4v8J0vAkV3z7XngeIIB3rM3650=", @@ -445,22 +424,6 @@ "type": "github" } }, - "nixpkgs_4": { - "locked": { - "lastModified": 1769461804, - "narHash": "sha256-msG8SU5WsBUfVVa/9RPLaymvi5bI8edTavbIq3vRlhI=", - "owner": "nixos", - "repo": "nixpkgs", - "rev": "bfc1b8a4574108ceef22f02bafcf6611380c100d", - "type": "github" - }, - "original": { - "owner": "nixos", - "ref": "nixos-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, "nixpkgs_5": { "locked": { "lastModified": 1769461804, @@ -522,29 +485,6 @@ "type": "github" } }, - "nvf": { - "inputs": { - "flake-compat": "flake-compat", - "flake-parts": "flake-parts_2", - "mnw": "mnw", - "ndg": "ndg", - "nixpkgs": "nixpkgs_4", - "systems": "systems" - }, - "locked": { - "lastModified": 1770213521, - "narHash": "sha256-ZUGJ3xZQfDcKCSBi0Qw7pSXWc2zkU8SxDJfsA7Uv8JI=", - "owner": "notashelf", - "repo": "nvf", - "rev": "9da5d517406c35b5bf738f446e5e51237f27b655", - "type": "github" - }, - "original": { - "owner": "notashelf", - "repo": "nvf", - "type": "github" - } - }, "root": { "inputs": { "copyparty": "copyparty", @@ -552,10 +492,10 @@ "flake-parts": "flake-parts", "home-manager": "home-manager", "import-tree": "import-tree", + "lazyvim": "lazyvim", "niri-flake": "niri-flake", - "nixpkgs": "nixpkgs_3", + "nixpkgs": "nixpkgs_4", "noctalia": "noctalia", - "nvf": "nvf", "sops-nix": "sops-nix", "spicetify-nix": "spicetify-nix", "stylix": "stylix" @@ -607,7 +547,7 @@ "base16-helix": "base16-helix", "base16-vim": "base16-vim", "firefox-gnome-theme": "firefox-gnome-theme", - "flake-parts": "flake-parts_3", + "flake-parts": "flake-parts_2", "gnome-shell": "gnome-shell", "nixpkgs": [ "nixpkgs" diff --git a/flake.nix b/flake.nix index 578608a..a7412cb 100644 --- a/flake.nix +++ b/flake.nix @@ -15,8 +15,8 @@ stylix.url = "github:nix-community/stylix/release-25.11"; stylix.inputs.nixpkgs.follows = "nixpkgs"; - nvf = { - url = "github:notashelf/nvf"; + lazyvim = { + url = "github:pfassina/lazyvim-nix"; }; firefox-addons = { diff --git a/modules/base/neovim.nix b/modules/base/neovim.nix index ed9c520..bfc1dda 100644 --- a/modules/base/neovim.nix +++ b/modules/base/neovim.nix @@ -1,53 +1,46 @@ {inputs, ...}: { - flake.modules.nixos.base = { - imports = [inputs.nvf.nixosModules.default]; + flake.modules.nixos.base = {pkgs, ...}: { + environment.systemPackages = [pkgs.neovim pkgs.statix]; - programs.nvf.enable = true; - nix.nixPath = ["nixpkgs=${inputs.nixpkgs}"]; - programs.nvf.settings = { - vim.viAlias = true; - vim.vimAlias = true; + programs.neovim.enable = true; + programs.neovim.defaultEditor = true; + }; - vim.autocomplete.blink-cmp.enable = true; - vim.telescope.enable = true; - vim.utility.sleuth.enable = true; - vim.binds.whichKey.enable = true; - vim.ui.noice.enable = true; - vim.statusline.lualine.enable = true; - vim.clipboard.enable = true; - vim.clipboard.registers = "unnamedplus"; - vim.presence.neocord.enable = true; - vim.filetree.neo-tree.enable = true; + flake.modules.homeManager.base = { + imports = [inputs.lazyvim.homeManagerModules.default]; - vim.git.neogit.enable = true; - vim.keymaps = [ - { - key = "gg"; - mode = "n"; - silent = true; - action = "Neogit"; - } - { - key = "fe"; - mode = "n"; - silent = true; - action = "Neotree toggle"; - } - ]; + programs.neovim.enable = true; + programs.neovim.defaultEditor = true; - vim.dashboard.alpha.enable = true; + programs.lazyvim = { + enable = true; + pluginSource = "nixpkgs"; + plugins.catppuccin = '' + return { "LazyVim/LazyVim", opts = { colorscheme = "catppuccin" } } + ''; + plugins.neogit = '' + return { "NeogitOrg/neogit", opts = {}, keys = { { "gg", "Neogit" } } } + ''; + extras = { + lang.nix = { + enable = true; + installDependencies = true; + }; - vim.lsp.enable = true; - vim.lsp.formatOnSave = true; - vim.languages = { - nix.enable = true; - nix.lsp.servers = ["nixd"]; - rust.enable = true; - ts.enable = true; - yaml.enable = true; + lang.python = { + enable = true; + installDependencies = true; + }; - enableTreesitter = true; - enableFormat = true; + # only reason we don't add `pkgs.claude-code` to base is because base is meant to be things for servers, + # we do need neovim on the server but we don't need a clanker on there too! + # + # plus, it can fail gracefully - if cc is not installed, it simply does nothing + ai.claudecode = { + enable = true; + installDependencies = true; + installRuntimeDependencies = true; + }; }; }; };