authorgravatar for nmarks413@gmail.comNatalie Marks <nmarks413@gmail.com> 2025-04-21 14:46:41-07:00
committergravatar for nmarks413@gmail.comNatalie Marks <nmarks413@gmail.com> 2025-04-21 14:46:41-07:00
logd1adefae9d4cffb0f27103d4bd1507d4df842371
treee36a10ff37c77500ee78b22fb65eb9e535dc5468
parent06569493a560cdd1b7e2abea2e76c6682b0955bc
signature Commit is signed but in an unrecognized format.

initial nixvim


8 files changed, 358 insertions(+), 13 deletions(-)

flake.lock+140-12
......@@ -168,6 +168,27 @@
168168 }
169169 },
170170 "flake-parts": {
171 "inputs": {
172 "nixpkgs-lib": [
173 "nixvim",
174 "nixpkgs"
175 ]
176 },
177 "locked": {
178 "lastModified": 1743550720,
179 "narHash": "sha256-hIshGgKZCgWh6AYJpJmRgFdR3WUbkY04o82X05xqQiY=",
180 "owner": "hercules-ci",
181 "repo": "flake-parts",
182 "rev": "c621e8422220273271f52058f618c94e405bb0f5",
183 "type": "github"
184 },
185 "original": {
186 "owner": "hercules-ci",
187 "repo": "flake-parts",
188 "type": "github"
189 }
190 },
191 "flake-parts_2": {
171192 "inputs": {
172193 "nixpkgs-lib": [
173194 "stylix",
......@@ -226,6 +247,24 @@
226247 }
227248 },
228249 "flake-utils_3": {
250 "inputs": {
251 "systems": "systems_3"
252 },
253 "locked": {
254 "lastModified": 1731533236,
255 "narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
256 "owner": "numtide",
257 "repo": "flake-utils",
258 "rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
259 "type": "github"
260 },
261 "original": {
262 "owner": "numtide",
263 "repo": "flake-utils",
264 "type": "github"
265 }
266 },
267 "flake-utils_4": {
229268 "inputs": {
230269 "systems": [
231270 "stylix",
......@@ -246,9 +285,9 @@
246285 "type": "github"
247286 }
248287 },
249 "flake-utils_4": {
288 "flake-utils_5": {
250289 "inputs": {
251 "systems": "systems_4"
290 "systems": "systems_5"
252291 },
253292 "locked": {
254293 "lastModified": 1705309234,
......@@ -264,9 +303,9 @@
264303 "type": "github"
265304 }
266305 },
267 "flake-utils_5": {
306 "flake-utils_6": {
268307 "inputs": {
269 "systems": "systems_5"
308 "systems": "systems_6"
270309 },
271310 "locked": {
272311 "lastModified": 1710146030,
......@@ -282,9 +321,9 @@
282321 "type": "github"
283322 }
284323 },
285 "flake-utils_6": {
324 "flake-utils_7": {
286325 "inputs": {
287 "systems": "systems_6"
326 "systems": "systems_7"
288327 },
289328 "locked": {
290329 "lastModified": 1705309234,
......@@ -460,6 +499,34 @@
460499 "type": "github"
461500 }
462501 },
502 "ixx": {
503 "inputs": {
504 "flake-utils": [
505 "nixvim",
506 "nuschtosSearch",
507 "flake-utils"
508 ],
509 "nixpkgs": [
510 "nixvim",
511 "nuschtosSearch",
512 "nixpkgs"
513 ]
514 },
515 "locked": {
516 "lastModified": 1737371634,
517 "narHash": "sha256-fTVAWzT1UMm1lT+YxHuVPtH+DATrhYfea3B0MxG/cGw=",
518 "owner": "NuschtOS",
519 "repo": "ixx",
520 "rev": "a1176e2a10ce745ff8f63e4af124ece8fe0b1648",
521 "type": "github"
522 },
523 "original": {
524 "owner": "NuschtOS",
525 "ref": "v0.0.7",
526 "repo": "ixx",
527 "type": "github"
528 }
529 },
463530 "langref": {
464531 "flake": false,
465532 "locked": {
......@@ -670,9 +737,31 @@
670737 "type": "github"
671738 }
672739 },
673 "nur": {
740 "nixvim": {
674741 "inputs": {
675742 "flake-parts": "flake-parts",
743 "nixpkgs": [
744 "nixpkgs"
745 ],
746 "nuschtosSearch": "nuschtosSearch"
747 },
748 "locked": {
749 "lastModified": 1745244491,
750 "narHash": "sha256-UlwXkytxGW/aokB9fZ6cSznYKM9ynDLHqhjcPve0KL4=",
751 "owner": "nix-community",
752 "repo": "nixvim",
753 "rev": "7a58109958d14bcece8ec3e2085e41ea3351e387",
754 "type": "github"
755 },
756 "original": {
757 "owner": "nix-community",
758 "repo": "nixvim",
759 "type": "github"
760 }
761 },
762 "nur": {
763 "inputs": {
764 "flake-parts": "flake-parts_2",
676765 "nixpkgs": [
677766 "stylix",
678767 "nixpkgs"
......@@ -693,6 +782,29 @@
693782 "type": "github"
694783 }
695784 },
785 "nuschtosSearch": {
786 "inputs": {
787 "flake-utils": "flake-utils_3",
788 "ixx": "ixx",
789 "nixpkgs": [
790 "nixvim",
791 "nixpkgs"
792 ]
793 },
794 "locked": {
795 "lastModified": 1745046075,
796 "narHash": "sha256-8v4y6k16Ra/fiecb4DxhsoOGtzLKgKlS+9/XJ9z0T2I=",
797 "owner": "NuschtOS",
798 "repo": "search",
799 "rev": "066afe8643274470f4a294442aadd988356a478f",
800 "type": "github"
801 },
802 "original": {
803 "owner": "NuschtOS",
804 "repo": "search",
805 "type": "github"
806 }
807 },
696808 "root": {
697809 "inputs": {
698810 "darwin": "darwin",
......@@ -704,6 +816,7 @@
704816 "nixos-cosmic": "nixos-cosmic",
705817 "nixpkgs": "nixpkgs_2",
706818 "nixpkgs-stable": "nixpkgs-stable_2",
819 "nixvim": "nixvim",
707820 "rust-overlay": "rust-overlay_2",
708821 "stylix": "stylix",
709822 "zig": "zig",
......@@ -759,7 +872,7 @@
759872 "base16-vim": "base16-vim",
760873 "firefox-gnome-theme": "firefox-gnome-theme",
761874 "flake-compat": "flake-compat_2",
762 "flake-utils": "flake-utils_3",
875 "flake-utils": "flake-utils_4",
763876 "git-hooks": "git-hooks",
764877 "gnome-shell": "gnome-shell",
765878 "home-manager": "home-manager_2",
......@@ -767,7 +880,7 @@
767880 "nixpkgs"
768881 ],
769882 "nur": "nur",
770 "systems": "systems_3",
883 "systems": "systems_4",
771884 "tinted-foot": "tinted-foot",
772885 "tinted-kitty": "tinted-kitty",
773886 "tinted-schemes": "tinted-schemes",
......@@ -878,6 +991,21 @@
878991 "type": "github"
879992 }
880993 },
994 "systems_7": {
995 "locked": {
996 "lastModified": 1681028828,
997 "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
998 "owner": "nix-systems",
999 "repo": "default",
1000 "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
1001 "type": "github"
1002 },
1003 "original": {
1004 "owner": "nix-systems",
1005 "repo": "default",
1006 "type": "github"
1007 }
1008 },
8811009 "tinted-foot": {
8821010 "flake": false,
8831011 "locked": {
......@@ -985,7 +1113,7 @@
9851113 "zig": {
9861114 "inputs": {
9871115 "flake-compat": "flake-compat_3",
988 "flake-utils": "flake-utils_4",
1116 "flake-utils": "flake-utils_5",
9891117 "nixpkgs": "nixpkgs_3"
9901118 },
9911119 "locked": {
......@@ -1005,7 +1133,7 @@
10051133 "zig-overlay": {
10061134 "inputs": {
10071135 "flake-compat": "flake-compat_4",
1008 "flake-utils": "flake-utils_6",
1136 "flake-utils": "flake-utils_7",
10091137 "nixpkgs": [
10101138 "zls",
10111139 "nixpkgs"
......@@ -1027,7 +1155,7 @@
10271155 },
10281156 "zls": {
10291157 "inputs": {
1030 "flake-utils": "flake-utils_5",
1158 "flake-utils": "flake-utils_6",
10311159 "gitignore": "gitignore_3",
10321160 "langref": "langref",
10331161 "nixpkgs": "nixpkgs_4",
flake.nix+5
......@@ -13,6 +13,11 @@
1313 inputs.nixpkgs.follows = "nixpkgs";
1414 };
1515
16 nixvim = {
17 url = "github:nix-community/nixvim";
18 inputs.nixpkgs.follows = "nixpkgs";
19 };
20
1621 darwin = {
1722 url = "github:lnl7/nix-darwin/master";
1823 inputs.nixpkgs.follows = "nixpkgs";
hosts/laptop/home.nix+7-1
......@@ -4,9 +4,15 @@
44 pkgs,
55 lib,
66 userSettings,
7 systemSettings,
78 ...
89}: {
9 programs = import ../../modules/shared/homeManagerPrograms.nix {inherit inputs config pkgs lib userSettings;};
10 imports = [
11 inputs.nixvim.homeManagerModules.nixvim
12 #set up nixvim
13 ../../modules/nixvim
14 ];
15 programs = import ../../modules/shared/homeManagerPrograms.nix {inherit inputs config pkgs lib userSettings systemSettings;};
1016
1117 home = {
1218 inherit (userSettings) username;
lib/mkSystem.nix+1
......@@ -21,6 +21,7 @@
2121 else inputs.stylix.nixosModules.stylix;
2222
2323 systemSettings = rec {
24 inherit darwin;
2425 host =
2526 if darwin
2627 then userSettings.darwinHost
modules/nixvim/default.nix created+98
......@@ -0,0 +1,98 @@
1{
2 pkgs,
3 inputs,
4 nixvim,
5 ...
6}: {
7 imports = [
8 ./opts.nix
9 ./keymaps.nix
10 ./plugins
11 ];
12 programs.nixvim = {
13 enable = true;
14
15 defaultEditor = true;
16
17 globals = {
18 #Set leader to space, and localleader to \
19 mapleader = " ";
20 maplocalleader = "\\";
21
22 have_nerd_font = true;
23 };
24
25 clipboard = {
26 providers = {
27 wl-copy.enable = true; # For Wayland
28 xsel.enable = true; # For X11
29 };
30
31 # Sync clipboard between OS and Neovim
32 # Remove this option if you want your OS clipboard to remain independent.
33 register = "unnamedplus";
34 };
35
36 opts = {
37 # Show line numbers
38 number = true;
39 # You can also add relative line numbers, to help with jumping.
40 # Experiment for yourself to see if you like it!
41 #relativenumber = true
42
43 # Enable mouse mode, can be useful for resizing splits for example!
44 mouse = "a";
45
46 # Don't show the mode, since it's already in the statusline
47 showmode = false;
48
49 # Enable break indent
50 breakindent = true;
51
52 # Save undo history
53 undofile = true;
54
55 # Case-insensitive searching UNLESS \C or one or more capital letters in the search term
56 ignorecase = true;
57 smartcase = true;
58
59 # Keep signcolumn on by default
60 signcolumn = "yes";
61
62 # Decrease update time
63 updatetime = 250;
64
65 # Decrease mapped sequence wait time
66 # Displays which-key popup sooner
67 timeoutlen = 300;
68
69 # Configure how new splits should be opened
70 splitright = true;
71 splitbelow = true;
72
73 # Sets how neovim will display certain whitespace characters in the editor
74 # See `:help 'list'`
75 # and `:help 'listchars'`
76 list = true;
77 # NOTE: .__raw here means that this field is raw lua code
78 listchars.__raw = "{ tab = '» ', trail = '·', nbsp = '␣' }";
79
80 # Preview substitutions live, as you type!
81 inccommand = "split";
82
83 # Show which line your cursor is on
84 cursorline = true;
85
86 # Minimal number of screen lines to keep above and below the cursor.
87 scrolloff = 10;
88
89 # if performing an operation that would fail due to unsaved changes in the buffer (like `:q`),
90 # instead raise a dialog asking if you wish to save the current file(s)
91 # See `:help 'confirm'`
92 confirm = true;
93
94 # See `:help hlsearch`
95 hlsearch = true;
96 };
97 };
98}
modules/nixvim/keymaps.nix created+42
......@@ -0,0 +1,42 @@
1{pkgs, ...}: {
2 programs.nixvim = {
3 keymaps = [
4 # Keybinds to make split navigation easier.
5 # Use CTRL+<hjkl> to switch between windows
6 #
7 # See `:help wincmd` for a list of all window commands
8 {
9 mode = "n";
10 key = "<C-h>";
11 action = "<C-w><C-h>";
12 options = {
13 desc = "Move focus to the left window";
14 };
15 }
16 {
17 mode = "n";
18 key = "<C-l>";
19 action = "<C-w><C-l>";
20 options = {
21 desc = "Move focus to the right window";
22 };
23 }
24 {
25 mode = "n";
26 key = "<C-j>";
27 action = "<C-w><C-j>";
28 options = {
29 desc = "Move focus to the lower window";
30 };
31 }
32 {
33 mode = "n";
34 key = "<C-k>";
35 action = "<C-w><C-k>";
36 options = {
37 desc = "Move focus to the upper window";
38 };
39 }
40 ];
41 };
42}
modules/nixvim/opts.nix created+65
......@@ -0,0 +1,65 @@
1{pkgs, ...}: {
2 programs.nixvim = {
3 opts = {
4 # Show line numbers
5 number = true;
6 # You can also add relative line numbers, to help with jumping.
7 # Experiment for yourself to see if you like it!
8 #relativenumber = true
9
10 # Enable mouse mode, can be useful for resizing splits for example!
11 mouse = "a";
12
13 # Don't show the mode, since it's already in the statusline
14 showmode = false;
15
16 # Enable break indent
17 breakindent = true;
18
19 # Save undo history
20 undofile = true;
21
22 # Case-insensitive searching UNLESS \C or one or more capital letters in the search term
23 ignorecase = true;
24 smartcase = true;
25
26 # Keep signcolumn on by default
27 signcolumn = "yes";
28
29 # Decrease update time
30 updatetime = 250;
31
32 # Decrease mapped sequence wait time
33 # Displays which-key popup sooner
34 timeoutlen = 300;
35
36 # Configure how new splits should be opened
37 splitright = true;
38 splitbelow = true;
39
40 # Sets how neovim will display certain whitespace characters in the editor
41 # See `:help 'list'`
42 # and `:help 'listchars'`
43 list = true;
44 # NOTE: .__raw here means that this field is raw lua code
45 listchars.__raw = "{ tab = '» ', trail = '·', nbsp = '␣' }";
46
47 # Preview substitutions live, as you type!
48 inccommand = "split";
49
50 # Show which line your cursor is on
51 cursorline = true;
52
53 # Minimal number of screen lines to keep above and below the cursor.
54 scrolloff = 10;
55
56 # if performing an operation that would fail due to unsaved changes in the buffer (like `:q`),
57 # instead raise a dialog asking if you wish to save the current file(s)
58 # See `:help 'confirm'`
59 confirm = true;
60
61 # See `:help hlsearch`
62 hlsearch = true;
63 };
64 };
65}
modules/nixvim/plugins/default.nix created