aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaroline Larimore <caroline@larimo.re>2025-06-20 20:49:57 -0700
committerCaroline Larimore <caroline@larimo.re>2025-06-20 20:49:57 -0700
commit970fb13fccc14ecca832241433220c1ab58fbcd8 (patch)
tree68bf119e7874631b2df6dc6494400fad30393a4e
parentd6409d34c41191491c4ec4bf9022db6264c10ea4 (diff)
nixvim: basic config
-rw-r--r--flake.lock146
-rw-r--r--flake.nix9
-rw-r--r--modules/home/suites/dev/default.nix1
-rw-r--r--modules/home/tools/neovim/default.nix39
-rw-r--r--overlays/asm-lsp/default.nix19
5 files changed, 213 insertions, 1 deletions
diff --git a/flake.lock b/flake.lock
index 749571e..31d89c3 100644
--- a/flake.lock
+++ b/flake.lock
@@ -32,6 +32,27 @@
"type": "github"
}
},
+ "flake-parts": {
+ "inputs": {
+ "nixpkgs-lib": [
+ "nixvim",
+ "nixpkgs"
+ ]
+ },
+ "locked": {
+ "lastModified": 1743550720,
+ "narHash": "sha256-hIshGgKZCgWh6AYJpJmRgFdR3WUbkY04o82X05xqQiY=",
+ "owner": "hercules-ci",
+ "repo": "flake-parts",
+ "rev": "c621e8422220273271f52058f618c94e405bb0f5",
+ "type": "github"
+ },
+ "original": {
+ "owner": "hercules-ci",
+ "repo": "flake-parts",
+ "type": "github"
+ }
+ },
"flake-utils": {
"inputs": {
"systems": "systems"
@@ -52,7 +73,7 @@
},
"flake-utils-plus": {
"inputs": {
- "flake-utils": "flake-utils_2"
+ "flake-utils": "flake-utils_3"
},
"locked": {
"lastModified": 1715533576,
@@ -74,6 +95,24 @@
"systems": "systems_2"
},
"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"
+ }
+ },
+ "flake-utils_3": {
+ "inputs": {
+ "systems": "systems_4"
+ },
+ "locked": {
"lastModified": 1694529238,
"narHash": "sha256-zsNZZGTGnMOf9YpHKJqMSsa0dXbfmxeoJ7xHlrt+xmY=",
"owner": "numtide",
@@ -122,6 +161,34 @@
"type": "github"
}
},
+ "ixx": {
+ "inputs": {
+ "flake-utils": [
+ "nixvim",
+ "nuschtosSearch",
+ "flake-utils"
+ ],
+ "nixpkgs": [
+ "nixvim",
+ "nuschtosSearch",
+ "nixpkgs"
+ ]
+ },
+ "locked": {
+ "lastModified": 1737371634,
+ "narHash": "sha256-fTVAWzT1UMm1lT+YxHuVPtH+DATrhYfea3B0MxG/cGw=",
+ "owner": "NuschtOS",
+ "repo": "ixx",
+ "rev": "a1176e2a10ce745ff8f63e4af124ece8fe0b1648",
+ "type": "github"
+ },
+ "original": {
+ "owner": "NuschtOS",
+ "ref": "v0.0.7",
+ "repo": "ixx",
+ "type": "github"
+ }
+ },
"nix-minecraft": {
"inputs": {
"flake-compat": "flake-compat",
@@ -174,12 +241,59 @@
"type": "github"
}
},
+ "nixvim": {
+ "inputs": {
+ "flake-parts": "flake-parts",
+ "nixpkgs": [
+ "nixpkgs"
+ ],
+ "nuschtosSearch": "nuschtosSearch",
+ "systems": "systems_3"
+ },
+ "locked": {
+ "lastModified": 1748088865,
+ "narHash": "sha256-xfAT2ykSAWcYgxkyZN5n6xRHab93u56zbBjuhoDFKFg=",
+ "owner": "nix-community",
+ "repo": "nixvim",
+ "rev": "2c0a9ff1e2bcc6aab15caa504a7c9670f6e0a929",
+ "type": "github"
+ },
+ "original": {
+ "owner": "nix-community",
+ "repo": "nixvim",
+ "type": "github"
+ }
+ },
+ "nuschtosSearch": {
+ "inputs": {
+ "flake-utils": "flake-utils_2",
+ "ixx": "ixx",
+ "nixpkgs": [
+ "nixvim",
+ "nixpkgs"
+ ]
+ },
+ "locked": {
+ "lastModified": 1745046075,
+ "narHash": "sha256-8v4y6k16Ra/fiecb4DxhsoOGtzLKgKlS+9/XJ9z0T2I=",
+ "owner": "NuschtOS",
+ "repo": "search",
+ "rev": "066afe8643274470f4a294442aadd988356a478f",
+ "type": "github"
+ },
+ "original": {
+ "owner": "NuschtOS",
+ "repo": "search",
+ "type": "github"
+ }
+ },
"root": {
"inputs": {
"home-manager": "home-manager",
"impermanence": "impermanence",
"nix-minecraft": "nix-minecraft",
"nixpkgs": "nixpkgs_2",
+ "nixvim": "nixvim",
"snowfall-lib": "snowfall-lib"
}
},
@@ -234,6 +348,36 @@
"repo": "default",
"type": "github"
}
+ },
+ "systems_3": {
+ "locked": {
+ "lastModified": 1681028828,
+ "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
+ "owner": "nix-systems",
+ "repo": "default",
+ "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
+ "type": "github"
+ },
+ "original": {
+ "owner": "nix-systems",
+ "repo": "default",
+ "type": "github"
+ }
+ },
+ "systems_4": {
+ "locked": {
+ "lastModified": 1681028828,
+ "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
+ "owner": "nix-systems",
+ "repo": "default",
+ "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
+ "type": "github"
+ },
+ "original": {
+ "owner": "nix-systems",
+ "repo": "default",
+ "type": "github"
+ }
}
},
"root": "root",
diff --git a/flake.nix b/flake.nix
index c072d56..bebfca0 100644
--- a/flake.nix
+++ b/flake.nix
@@ -16,6 +16,11 @@
impermanence.url = "github:nix-community/impermanence";
nix-minecraft.url = "github:CartConnoisseur/nix-minecraft";
+
+ nixvim = {
+ url = "github:nix-community/nixvim";
+ inputs.nixpkgs.follows = "nixpkgs";
+ };
};
outputs = inputs: inputs.snowfall-lib.mkFlake {
@@ -37,6 +42,10 @@
nix-minecraft.nixosModules.minecraft-servers
];
+ homes.modules = with inputs; [
+ nixvim.homeManagerModules.nixvim
+ ];
+
overlays = with inputs; [
nix-minecraft.overlay
];
diff --git a/modules/home/suites/dev/default.nix b/modules/home/suites/dev/default.nix
index 3d54f9b..710f627 100644
--- a/modules/home/suites/dev/default.nix
+++ b/modules/home/suites/dev/default.nix
@@ -26,6 +26,7 @@ in {
cloc.enable = true;
tmux.enable = true;
mkenv.enable = true;
+ neovim.enable = true;
fork.enable = desktop.enable;
};
};
diff --git a/modules/home/tools/neovim/default.nix b/modules/home/tools/neovim/default.nix
new file mode 100644
index 0000000..0cac0c2
--- /dev/null
+++ b/modules/home/tools/neovim/default.nix
@@ -0,0 +1,39 @@
+{ options, config, lib, pkgs, namespace, ... }:
+
+with lib; with lib.${namespace}; let
+ cfg = config.${namespace}.tools.neovim;
+ theme = config.${namespace}.desktop.theme;
+in {
+ options.${namespace}.tools.neovim = with types; {
+ enable = mkEnableOption "neovim";
+ };
+
+ config = mkIf cfg.enable {
+ programs.nixvim = {
+ enable = true;
+
+ colorschemes."${theme.vim}".enable = true;
+
+ opts = {
+ number = true;
+ relativenumber = true;
+ };
+
+ extraConfigVim = ''
+ highlight Normal guibg=NONE
+ '';
+
+ plugins.lsp = {
+ enable = true;
+
+ servers = {
+ zls.enable = true;
+ asm_lsp.enable = true;
+ };
+ };
+
+ plugins.nix.enable = true;
+ plugins.trouble.enable = true;
+ };
+ };
+}
diff --git a/overlays/asm-lsp/default.nix b/overlays/asm-lsp/default.nix
new file mode 100644
index 0000000..ae07556
--- /dev/null
+++ b/overlays/asm-lsp/default.nix
@@ -0,0 +1,19 @@
+{ ... }:
+
+final: prev: {
+ asm-lsp = prev.asm-lsp.overrideAttrs (old: rec {
+ version = "git";
+
+ src = prev.fetchFromGitHub {
+ owner = "bergercookie";
+ repo = "asm-lsp";
+ rev = "5a2c112aa3b41ed736064d7f2bf4cc41775fd53f";
+ hash = "sha256-Kz1+SbFD0NTX3Sj22mdX1RV/qLbZfEyr1gc8T7nwOmQ=";
+ };
+
+ cargoDeps = prev.rustPlatform.fetchCargoVendor {
+ inherit src;
+ hash = "sha256-4GbKT8+TMf2o563blj8lnZTD7Lc+z9yW11TfxYzDSg4=";
+ };
+ });
+}