tangled
alpha
login
or
join now
dunkirk.sh
/
dots
3
fork
atom
Kieran's opinionated (and probably slightly dumb) nix config
3
fork
atom
overview
issues
pulls
pipelines
feat: added lazyvim config
Kieran Klukas
2 years ago
650ebdcb
93993637
+128
-1
3 changed files
expand all
collapse all
unified
split
home-manager
home.nix
neovim.nix
moonlark
configuration.nix
+2
-1
home-manager/home.nix
···
27
27
# ./hyprland
28
28
29
29
./waybar.nix
30
30
+
31
31
+
./neovim.nix
30
32
];
31
33
32
34
nixpkgs = {
···
416
418
obs-pipewire-audio-capture
417
419
];
418
420
};
419
419
-
420
421
421
422
# Nicely reload system units when changing configs
422
423
systemd.user.startServices = "sd-switch";
+125
home-manager/neovim.nix
···
1
1
+
{ config, lib, pkgs, ... }:
2
2
+
3
3
+
{
4
4
+
programs.neovim = {
5
5
+
enable = true;
6
6
+
extraPackages = with pkgs; [
7
7
+
# LazyVim
8
8
+
lua-language-server
9
9
+
stylua
10
10
+
# Telescope
11
11
+
ripgrep
12
12
+
];
13
13
+
14
14
+
plugins = with pkgs.vimPlugins; [
15
15
+
lazy-nvim
16
16
+
];
17
17
+
18
18
+
defaultEditor = true;
19
19
+
viAlias = true;
20
20
+
vimAlias = true;
21
21
+
22
22
+
extraLuaConfig =
23
23
+
let
24
24
+
plugins = with pkgs.vimPlugins; [
25
25
+
# LazyVim
26
26
+
LazyVim
27
27
+
bufferline-nvim
28
28
+
cmp-buffer
29
29
+
cmp-nvim-lsp
30
30
+
cmp-path
31
31
+
cmp_luasnip
32
32
+
conform-nvim
33
33
+
dashboard-nvim
34
34
+
dressing-nvim
35
35
+
flash-nvim
36
36
+
friendly-snippets
37
37
+
gitsigns-nvim
38
38
+
indent-blankline-nvim
39
39
+
lualine-nvim
40
40
+
neo-tree-nvim
41
41
+
neoconf-nvim
42
42
+
neodev-nvim
43
43
+
noice-nvim
44
44
+
nui-nvim
45
45
+
nvim-cmp
46
46
+
nvim-lint
47
47
+
nvim-lspconfig
48
48
+
nvim-notify
49
49
+
nvim-spectre
50
50
+
nvim-treesitter
51
51
+
nvim-treesitter-context
52
52
+
nvim-treesitter-textobjects
53
53
+
nvim-ts-autotag
54
54
+
nvim-ts-context-commentstring
55
55
+
nvim-web-devicons
56
56
+
persistence-nvim
57
57
+
plenary-nvim
58
58
+
telescope-fzf-native-nvim
59
59
+
telescope-nvim
60
60
+
todo-comments-nvim
61
61
+
tokyonight-nvim
62
62
+
trouble-nvim
63
63
+
vim-illuminate
64
64
+
vim-startuptime
65
65
+
which-key-nvim
66
66
+
{ name = "LuaSnip"; path = luasnip; }
67
67
+
{ name = "catppuccin"; path = catppuccin-nvim; }
68
68
+
{ name = "mini.ai"; path = mini-nvim; }
69
69
+
{ name = "mini.bufremove"; path = mini-nvim; }
70
70
+
{ name = "mini.comment"; path = mini-nvim; }
71
71
+
{ name = "mini.indentscope"; path = mini-nvim; }
72
72
+
{ name = "mini.pairs"; path = mini-nvim; }
73
73
+
{ name = "mini.surround"; path = mini-nvim; }
74
74
+
];
75
75
+
mkEntryFromDrv = drv:
76
76
+
if lib.isDerivation drv then
77
77
+
{ name = "${lib.getName drv}"; path = drv; }
78
78
+
else
79
79
+
drv;
80
80
+
lazyPath = pkgs.linkFarm "lazy-plugins" (builtins.map mkEntryFromDrv plugins);
81
81
+
in
82
82
+
''
83
83
+
require("lazy").setup({
84
84
+
defaults = {
85
85
+
lazy = true,
86
86
+
},
87
87
+
dev = {
88
88
+
-- reuse files from pkgs.vimPlugins.*
89
89
+
path = "${lazyPath}",
90
90
+
patterns = { "." },
91
91
+
-- fallback to download
92
92
+
fallback = true,
93
93
+
},
94
94
+
spec = {
95
95
+
{ "LazyVim/LazyVim", import = "lazyvim.plugins" },
96
96
+
-- The following configs are needed for fixing lazyvim on nix
97
97
+
-- force enable telescope-fzf-native.nvim
98
98
+
{ "nvim-telescope/telescope-fzf-native.nvim", enabled = true },
99
99
+
-- disable mason.nvim, use programs.neovim.extraPackages
100
100
+
{ "williamboman/mason-lspconfig.nvim", enabled = false },
101
101
+
{ "williamboman/mason.nvim", enabled = false },
102
102
+
-- import/override with your plugins
103
103
+
{ import = "plugins" },
104
104
+
-- treesitter handled by xdg.configFile."nvim/parser", put this line at the end of spec to clear ensure_installed
105
105
+
{ "nvim-treesitter/nvim-treesitter", opts = { ensure_installed = {} } },
106
106
+
},
107
107
+
})
108
108
+
'';
109
109
+
};
110
110
+
111
111
+
# https://github.com/nvim-treesitter/nvim-treesitter#i-get-query-error-invalid-node-type-at-position
112
112
+
xdg.configFile."nvim/parser".source =
113
113
+
let
114
114
+
parsers = pkgs.symlinkJoin {
115
115
+
name = "treesitter-parsers";
116
116
+
paths = (pkgs.vimPlugins.nvim-treesitter.withPlugins (plugins: with plugins; [
117
117
+
c
118
118
+
lua
119
119
+
])).dependencies;
120
120
+
};
121
121
+
in
122
122
+
"${parsers}/parser";
123
123
+
124
124
+
# Normal LazyVim config here, see https://github.com/LazyVim/starter/tree/main/lua
125
125
+
}
+1
moonlark/configuration.nix
···
109
109
pkgs.pitivi
110
110
pkgs.unstable.arduino-ide
111
111
pkgs.unstable.arduino-cli
112
112
+
pkgs.lazygit
112
113
];
113
114
114
115
services.gnome.gnome-keyring.enable = true;