reinit git

This commit is contained in:
2026-07-04 04:46:11 +02:00
commit 524ee6e1ce
61 changed files with 5183 additions and 0 deletions
+28
View File
@@ -0,0 +1,28 @@
{
pkgs,
...
}: {
vim = {
autocomplete = {
nvim-cmp = {
enable = true;
sources = {
nvim_lsp = "[LSP]";
path = "[PATH]";
nvim_lua = "[LUA]";
};
sourcePlugins = [
"cmp-nvim-lsp"
"cmp-path"
];
};
};
extraLuaFiles = [
(builtins.path {
path = ./raw/cmp.lua;
name = "my-lua-file";
})
];
};
}
+9
View File
@@ -0,0 +1,9 @@
_:
{
vim.languages.clang = {
dap = {
enable = true;
debugger = "lldb-vscode";
};
};
}
+10
View File
@@ -0,0 +1,10 @@
_:
{
imports = [
./rust.nix
./clang.nix
./python.nix
];
}
+9
View File
@@ -0,0 +1,9 @@
_:
{
vim.languages.python = {
dap = {
enable = true;
debugger = "debugpy";
};
};
}
+8
View File
@@ -0,0 +1,8 @@
_:
{
vim.languages.rust = {
dap = {
enable = true;
};
};
}
+31
View File
@@ -0,0 +1,31 @@
{ ... }:
{
imports = [
./terminal.nix
./neotree.nix
./cmp.nix
./lualine.nix
./ui.nix
./lsp/default.nix
./dbg/default.nix
];
vim = {
extraLuaFiles = [
(builtins.path {
path = ./raw/opts.lua;
name = "opts.lua";
})
];
autopairs.nvim-autopairs.enable = true;
telescope.enable = true;
autocomplete = { enableSharedCmpSources = true; };
binds = {
whichKey = {
enable = true;
#setupOpts.preset = "helix";
};
};
};
}
+156
View File
@@ -0,0 +1,156 @@
{
"nodes": {
"flake-compat": {
"flake": false,
"locked": {
"lastModified": 1777699697,
"narHash": "sha256-Eg9b/rq/ECYwNwEXs5i9wHyhxNI0JrYx2srdI2uZMaQ=",
"ref": "refs/heads/main",
"rev": "382052b74656a369c5408822af3f2501e9b1af81",
"revCount": 94,
"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": [
"nvf",
"nixpkgs"
]
},
"locked": {
"lastModified": 1778716662,
"narHash": "sha256-m1Yf0wZ8j1OHjTc2UwHwyQRSnNeSgLJOd7q5Y45hzi4=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "f7c1a2d347e4c52d5fb8d10cb4d94b5884e546fb",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "flake-parts",
"type": "github"
}
},
"mnw": {
"locked": {
"lastModified": 1780772958,
"narHash": "sha256-VKKe8r4pwCGWZ3Yr9CPN129R4S3CKLSrlYqdYz3vKpM=",
"owner": "Gerg-L",
"repo": "mnw",
"rev": "0871dbf63a53610c95db04439ed8ea4d6ec9c160",
"type": "github"
},
"original": {
"owner": "Gerg-L",
"repo": "mnw",
"type": "github"
}
},
"ndg": {
"inputs": {
"nixpkgs": [
"nvf",
"nixpkgs"
]
},
"locked": {
"lastModified": 1779233504,
"narHash": "sha256-YIKEyzh0NFQlD0O92LQQNMoVCDwV8yw1Xz0Iu+4ZC5U=",
"owner": "feel-co",
"repo": "ndg",
"rev": "86f6644411a64d5413711895b7cf6e0e1be465b6",
"type": "github"
},
"original": {
"owner": "feel-co",
"ref": "refs/tags/v2.8.0",
"repo": "ndg",
"type": "github"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1754214453,
"narHash": "sha256-Q/I2xJn/j1wpkGhWkQnm20nShYnG7TI99foDBpXm1SY=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "5b09dc45f24cf32316283e62aec81ffee3c3e376",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_2": {
"locked": {
"lastModified": 1781216227,
"narHash": "sha256-9mUW6gNwoN2SWc/l0fW4svPNOulXLl8ijqKyeSOGgJE=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "a0374025a863d007d98e3297f6aa46cc3141c2f0",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-26.05",
"repo": "nixpkgs",
"type": "github"
}
},
"nvf": {
"inputs": {
"flake-compat": "flake-compat",
"flake-parts": "flake-parts",
"mnw": "mnw",
"ndg": "ndg",
"nixpkgs": "nixpkgs_2",
"systems": "systems"
},
"locked": {
"lastModified": 1781534482,
"narHash": "sha256-d3UIqXuigQhsc7amQkZ7F+SWnaJFAxIROE2f2X+pzUs=",
"owner": "notashelf",
"repo": "nvf",
"rev": "63d8fc82d652c23419a837e2b2934dd4bead04f3",
"type": "github"
},
"original": {
"owner": "notashelf",
"repo": "nvf",
"type": "github"
}
},
"root": {
"inputs": {
"nixpkgs": "nixpkgs",
"nvf": "nvf"
}
},
"systems": {
"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",
"version": 7
}
+24
View File
@@ -0,0 +1,24 @@
{
description = "My autistic nvf config";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
nvf.url = "github:notashelf/nvf";
};
outputs = { nixpkgs, nvf, ... }: let
system = "x86_64-linux";
pkgs = nixpkgs.legacyPackages.${system};
nvimWrapped = nvf.lib.neovimConfiguration {
inherit pkgs;
modules = [ ./default.nix ];
};
in {
packages.${system}.default = nvimWrapped.neovim;
nixosModules.default = { ... }: {
imports = [ nvf.nixosModules.default ];
programs.nvf = { enable = true; settings = import ./default.nix; };
};
};
}
+9
View File
@@ -0,0 +1,9 @@
_:
{
vim.languages.assembly = {
enable = true;
lsp = {
enable = true;
};
};
}
+7
View File
@@ -0,0 +1,7 @@
_:
{
vim.languages.bash = {
enable = true;
lsp.enable = true;
};
}
+10
View File
@@ -0,0 +1,10 @@
_:
{
vim.languages.clang = {
enable = true;
lsp = {
enable = true;
server = "ccls";
};
};
}
+14
View File
@@ -0,0 +1,14 @@
_:
{
imports = [
./asm.nix
./bash.nix
./clang.nix
./go.nix
./lua.nix
./nix-lang.nix
./python.nix
./rust.nix
./lspkind.nix
];
}
+7
View File
@@ -0,0 +1,7 @@
_:
{
vim.languages.go = {
enable = true;
lsp.enable = true;
};
}
+14
View File
@@ -0,0 +1,14 @@
_:
{
vim = {
lsp = {
lspkind = {
enable = true;
setupOpts = {
mode = "symbol_text";
preset = "codicons";
};
};
};
};
}
+6
View File
@@ -0,0 +1,6 @@
_:
{
vim.languages.lua = {
enable = true;
};
}
+18
View File
@@ -0,0 +1,18 @@
_:
{
vim.languages.nix = {
enable = true;
extraDiagnostics = {
enable = true;
};
format = {
enable = true;
type = "alejandra";
};
lsp = {
enable = true;
server = "nixd";
};
};
}
+7
View File
@@ -0,0 +1,7 @@
_:
{
vim.languages.python = {
enable = true;
lsp.enable = true;
};
}
+9
View File
@@ -0,0 +1,9 @@
_:
{
vim.languages.rust = {
enable = true;
dap.enable = true;
format.enable = true;
lsp.enable = true;
};
}
+26
View File
@@ -0,0 +1,26 @@
_:
{
vim = {
statusline = {
lualine = {
enable = true;
theme = "base16";
globalStatus = true;
icons.enable = true;
ignoreFocus = [
"neo-tree"
"filename"
"location"
];
componentSeparator = {
left = "";
right = "";
};
sectionSeparator = {
left = "";
right = "";
};
};
};
};
}
+17
View File
@@ -0,0 +1,17 @@
{ pkgs, ... }: {
vim = {
filetree = {
neo-tree = {
enable = true;
setupOpts = {
enable = true;
enable_git_status = true;
enable_diagnostics = true;
enable_refresh_on_write = true;
auto_clean_after_session_restore = true;
git_status_async = true;
};
};
};
};
}
+75
View File
@@ -0,0 +1,75 @@
local cmp = require("cmp")
local lspkind = require("lspkind")
vim.opt.completeopt = { "menu", "menuone", "noinsert", "noselect" }
cmp.setup({
formatting = {
format = function(entry, vim_item)
vim_item.kind = lspkind.symbolic(vim_item.kind, { mode = "symbol_text" })[entry.source.name]
vim_item.dup = ({
vsnip = 0,
nvim_lsp = 0,
nvim_lua = 0,
buffer = 0,
})[entry.source.name] or 0
return vim_item
end,
},
sorting = {
comparators = {
cmp.config.compare.offset,
cmp.config.compare.exact,
cmp.config.compare.score,
cmp.config.compare.kind,
cmp.config.compare.sort_text,
cmp.config.compare.length,
cmp.config.compare.order,
},
},
window = {
completion = {
autocomplete = true,
col_offset = -3,
side_padding = 0,
},
completion = cmp.config.window.bordered({
winhighlight = "Normal:Pmenu,FloatBorder:Pmenu,CursorLine:PmenuSel,Search:None",
}),
documentation = cmp.config.window.bordered({
winhighlight = "Normal:Pmenu,FloatBorder:Pmenu,CursorLine:PmenuSel,Search:None",
}),
},
mapping = cmp.mapping.preset.insert({
["<Tab>"] = cmp.mapping(function(fallback)
if cmp.visible() then
cmp.select_next_item()
else
fallback()
end
end, { "i", "s" }),
["<S-Tab>"] = cmp.mapping(function(fallback)
if cmp.visible() then
cmp.select_prev_item()
else
fallback()
end
end, { "i", "s" }),
["<C-b>"] = cmp.mapping.scroll_docs(-4),
["<C-f>"] = cmp.mapping.scroll_docs(4),
["<C-Space>"] = cmp.mapping.complete(),
["<C-e>"] = cmp.mapping.abort(),
["<CR>"] = cmp.mapping.confirm({ select = false }),
}),
--sources = cmp.config.sources({
-- { name = 'nvim_lsp' },
-- { name = 'path' },
-- { name = 'nvim_lua' },
--}),
})
+40
View File
@@ -0,0 +1,40 @@
vim.opt.shiftwidth = 2
vim.opt.tabstop = 2
vim.opt.cursorline = true
vim.opt.cursorcolumn = true
vim.opt.expandtab = true
vim.opt.autoindent = true
vim.opt.smartindent = true
vim.opt.softtabstop = 2
vim.opt.relativenumber = true
vim.diagnostic.config({
virtual_text = true,
virtual_lines = false,
})
local map = vim.api.nvim_set_keymap
local opts = { noremap = true, silent = true }
vim.g.mapleader = "\\"
map('n', '<c-t>', ":ToggleTerm size=15<CR>", opts)
map('n', '<leader>n', ":Neotree filesystem reveal toggle<CR>", opts)
map('v', '<Tab>', '>gv', opts)
map('v', '<S-Tab>', '<gv', opts)
map('n', '<leader>ff', 'Telescope find_files<CR>', opts)
map('n', '<leader>gs', 'Telescope grep_string<CR>', opts)
vim.cmd [[
set nobackup
cnoreabbrev W! w!
cnoreabbrev Q! q!
cnoreabbrev Qall! qall!
cnoreabbrev Wq wq
cnoreabbrev Wa wa
cnoreabbrev wQ wq
cnoreabbrev WQ wq
cnoreabbrev W w
cnoreabbrev Q q
cnoreabbrev Qall qall
]]
+13
View File
@@ -0,0 +1,13 @@
{
pkgs,
...
}: {
vim = {
terminal = {
toggleterm = {
enable = true;
lazygit.enable = true;
};
};
};
}
+32
View File
@@ -0,0 +1,32 @@
_:
{
vim = {
tabline = {
nvimBufferline = {
enable = false;
};
};
ui = {
borders = {
enable = true;
globalStyle = "rounded";
};
colorful-menu-nvim.enable = true;
colorizer.enable = true;
};
theme = {
enable = true;
name = "oxocarbon";
style = "dark";
};
visuals = {
indent-blankline.enable = true;
fidget-nvim.enable = true;
nvim-web-devicons.enable = true;
};
dashboard.alpha = {
enable = true;
theme = "startify";
};
};
}