Compare commits

..

No commits in common. "2f48251e914cde10985fdd551c3bdcc85e960c79" and "16f98ffe582fe1273f442ce0a213a7dfef88535d" have entirely different histories.

9 changed files with 128 additions and 232 deletions

View file

@ -21,7 +21,6 @@
# UI plugins # UI plugins
./plugins/ui/lualine.nix ./plugins/ui/lualine.nix
./plugins/ui/web-devicons.nix
# LSP and formatting # LSP and formatting
./plugins/lsp/conform.nix ./plugins/lsp/conform.nix
@ -33,7 +32,6 @@
./plugins/git/lazygit.nix ./plugins/git/lazygit.nix
# Utils # Utils
./plugins/utils/codecompanion.nix
./plugins/utils/markdown-preview.nix ./plugins/utils/markdown-preview.nix
./plugins/utils/telescope.nix ./plugins/utils/telescope.nix
./plugins/utils/whichkey.nix ./plugins/utils/whichkey.nix

View file

@ -18,15 +18,16 @@
''; '';
# cmp mappings declaration # cmp mappings declaration
mapping = { mapping = {
"<C-Tab>" = "cmp.mapping(cmp.mapping.select_next_item(), {'i', 's'})"; # Select next/previous item.
"<C-e>" = "cmp.mapping.select_next_item()"; "<Tab>" = "cmp.mapping(cmp.mapping.select_next_item(), {'i', 's'})";
"<C-n>" = "cmp.mapping.select_prev_item()"; "<S-Tab>" = "cmp.mapping(cmp.mapping.select_prev_item(), {'i', 's'})";
"<C-esc>" = "cmp.mapping.abort()"; # Scroll through documentation.
"<C-b>" = "cmp.mapping.scroll_docs(-4)"; "<C-s>" = "cmp.mapping.scroll_docs(-4)";
"<C-f>" = "cmp.mapping.scroll_docs(4)"; "<C-t>" = "cmp.mapping.scroll_docs(4)";
"<C-Space>" = "cmp.mapping.complete()"; # Confirm selection.
"<C-CR>" = "cmp.mapping.confirm({ select = true })"; "<CR>" = "cmp.mapping.confirm({ behavior = cmp.ConfirmBehavior.Replace, select = true })";
"<S-CR>" = "cmp.mapping.confirm({ behavior = cmp.ConfirmBehavior.Replace, select = true })"; # Exit completion.
"<C-e>" = "cmp.mapping.abort()";
}; };
}; };
# Scans the sources array and enable the corresponding plugins if they are known to nixvim. # Scans the sources array and enable the corresponding plugins if they are known to nixvim.

View file

@ -2,12 +2,13 @@
plugins.conform-nvim = { plugins.conform-nvim = {
enable = true; enable = true;
settings = {
# Run the formatter on file save. # Run the formatter on file save.
format_on_save = { formatOnSave = {
lspFallback = true; lspFallback = true;
timeoutMs = 500; timeoutMs = 500;
}; };
# Receive notificaton when a formatter errors.
notifyOnError = true;
# Map of filetype to formatters. # Map of filetype to formatters.
formattersByFt = { formattersByFt = {
@ -16,10 +17,6 @@
lua = ["stylua"]; lua = ["stylua"];
nix = ["alejandra"]; nix = ["alejandra"];
}; };
# Receive notificaton when a formatter errors.
notifyOnError = true;
};
}; };
# Install our formatters. # Install our formatters.

View file

@ -9,20 +9,19 @@
enable = true; enable = true;
}; };
# Clojure # Clojure
clojure_lsp = { clojure-lsp = {
enable = true; enable = true;
}; };
# Haskell # Haskell
hls = { hls = {
enable = true; enable = true;
installGhc = true;
}; };
# Lua # Lua
lua_ls = { lua-ls = {
enable = true; enable = true;
}; };
# Nix # Nix
nil_ls = { nil-ls = {
enable = true; enable = true;
}; };
# YAML # YAML

View file

@ -1,7 +1,7 @@
{...}: { {...}: {
plugins.luasnip = { plugins.luasnip = {
enable = true; enable = true;
settings = { extraConfig = {
enable_autosnippets = true; enable_autosnippets = true;
store_selection_keys = "<Tab>"; store_selection_keys = "<Tab>";
}; };

View file

@ -1,29 +1,29 @@
{...}: { {...}: {
plugins.lualine = { plugins.lualine = {
enable = true; enable = true;
settings = {
options = {
globalstatus = true; globalstatus = true;
theme = "gruvbox-material"; theme = "gruvbox-material";
# Load our extensions
extensions = [
"neo-tree"
];
# Icons for our separators # Icons for our separators
componentSeparators = { componentSeparators = {
left = ""; left = "";
right = ""; right = "";
}; };
sectionSeparators = { sectionSeparators = {
left = ""; left = "";
right = ""; right = "";
}; };
};
# Display components in tabline # Display components in tabline
tabline = { tabline = {
lualine_a = [{__unkeyed-1 = "buffers";}]; lualine_a = [{name = "buffers";}];
lualine_x = [{__unkeyed-1 = "hostname";}]; lualine_x = [{name = "hostname";}];
lualine_z = [{__unkeyed-1 = "encoding";}]; lualine_z = [{name = "encoding";}];
}; };
# Lualine has sections as shown below # Lualine has sections as shown below
@ -32,20 +32,20 @@
# +-------------------------------------------------+ # +-------------------------------------------------+
sections = { sections = {
# Section A # Section A
lualine_a = [{__unkeyed-1 = "mode";}]; lualine_a = [{name = "mode";}];
# Section B # Section B
lualine_b = [ lualine_b = [
# Git branch # Git branch
{ {
__unkeyed-1 = "branch"; name = "branch";
icon = ""; icon = "";
} }
# Git diff status # Git diff status
{ {
__unkeyed-1 = "diff"; name = "diff";
symbols = { extraConfig.symbols = {
added = "+"; added = "+";
modified = "~"; modified = "~";
removed = "-"; removed = "-";
@ -54,13 +54,14 @@
]; ];
# Section C # Section C
lualine_c = [{__unkeyed-1 = "filename";}]; lualine_c = [{name = "filename";}];
# Section X # Section X
lualine_x = [ lualine_x = [
# Diagnostic count from nvim_lsp # Diagnostic count from nvim_lsp
{ {
__unkeyed-1 = "diagnostics"; name = "diagnostics";
extraConfig = {
sources = ["nvim_lsp"]; sources = ["nvim_lsp"];
symbols = { symbols = {
error = "error:"; error = "error:";
@ -68,20 +69,15 @@
info = "info:"; info = "info:";
hint = "hint:"; hint = "hint:";
}; };
};
} }
]; ];
# Section Y # Section Y
lualine_y = [{__unkeyed-1 = "progress";}]; lualine_y = [{name = "progress";}];
# Section Z # Section Z
lualine_z = [{__unkeyed-1 = "location";}]; lualine_z = [{name = "location";}];
};
# Load our extensions
extensions = [
"neo-tree"
];
}; };
}; };
} }

View file

@ -1,5 +0,0 @@
{...}: {
plugins.web-devicons = {
enable = true;
};
}

View file

@ -1,61 +0,0 @@
{...}: {
plugins.codecompanion = {
enable = true;
settings = {
adapters = {
ollama = {
__raw = ''
function()
return require('codecompanion.adapters').extend('ollama', {
env = {
url = "http://127.0.0.1:11434",
},
schema = {
model = {
default = 'deepseek-coder-v2:latest',
},
num_ctx = {
default = 4096,
},
num_predict = {
default = -1,
},
},
})
end
'';
};
};
opts = {
log_level = "TRACE";
send_code = true;
use_default_actions = true;
use_default_prompts = true;
};
strategies = {
agent = {
adapter = "ollama";
};
chat = {
adapter = "ollama";
};
inline = {
adapter = "ollama";
};
};
};
};
keymaps = [
{
mode = ["n" "v"];
key = "<leader>tc";
action = "<cmd>CodeCompanionChat Toggle<cr>";
options = {
silent = true;
desc = "Toggle CodeCompanion";
};
}
];
}

109
flake.lock generated
View file

@ -8,11 +8,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1728330715, "lastModified": 1722113426,
"narHash": "sha256-xRJ2nPOXb//u1jaBnDP56M7v5ldavjbtR6lfGqSvcKg=", "narHash": "sha256-Yo/3loq572A8Su6aY5GP56knpuKYRvM2a1meP9oJZCw=",
"owner": "numtide", "owner": "numtide",
"repo": "devshell", "repo": "devshell",
"rev": "dd6b80932022cea34a019e2bb32f6fa9e494dfef", "rev": "67cce7359e4cd3c45296fb4aaf6a19e2a9c757ae",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -40,11 +40,11 @@
"nixpkgs-lib": "nixpkgs-lib" "nixpkgs-lib": "nixpkgs-lib"
}, },
"locked": { "locked": {
"lastModified": 1733312601, "lastModified": 1722555600,
"narHash": "sha256-4pDvzqnegAfRkPwO3wmwBhVi/Sye1mzps0zHWYnP88c=", "narHash": "sha256-XOQkdLafnb/p9ij77byFQjDf5m5QYl9b2REiVClC+x4=",
"owner": "hercules-ci", "owner": "hercules-ci",
"repo": "flake-parts", "repo": "flake-parts",
"rev": "205b12d8b7cd4802fbcb8e8ef6a0f1408781a4f9", "rev": "8471fe90ad337a8074e957b69ca4d0089218391d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -61,11 +61,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1733312601, "lastModified": 1719994518,
"narHash": "sha256-4pDvzqnegAfRkPwO3wmwBhVi/Sye1mzps0zHWYnP88c=", "narHash": "sha256-pQMhCCHyQGRzdfAkdJ4cIWiw+JNuWsTX7f0ZYSyz0VY=",
"owner": "hercules-ci", "owner": "hercules-ci",
"repo": "flake-parts", "repo": "flake-parts",
"rev": "205b12d8b7cd4802fbcb8e8ef6a0f1408781a4f9", "rev": "9227223f6d922fee3c7b190b2cc238a99527bbb7",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -79,11 +79,11 @@
"systems": "systems" "systems": "systems"
}, },
"locked": { "locked": {
"lastModified": 1731533236, "lastModified": 1710146030,
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=", "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=",
"owner": "numtide", "owner": "numtide",
"repo": "flake-utils", "repo": "flake-utils",
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b", "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -109,11 +109,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1734425854, "lastModified": 1721042469,
"narHash": "sha256-nzE5UbJ41aPEKf8R2ZFYtLkqPmF7EIUbNEdHMBLg0Ig=", "narHash": "sha256-6FPUl7HVtvRHCCBQne7Ylp4p+dpP3P/OYuzjztZ4s70=",
"owner": "cachix", "owner": "cachix",
"repo": "git-hooks.nix", "repo": "git-hooks.nix",
"rev": "0ddd26d0925f618c3a5d85a4fa5eb1e23a09491d", "rev": "f451c19376071a90d8c58ab1a953c6e9840527fd",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -152,11 +152,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1734622215, "lastModified": 1722407237,
"narHash": "sha256-OOfI0XhSJGHblfdNDhfnn8QnZxng63rWk9eeJ2tCbiI=", "narHash": "sha256-wcpVHUc2nBSSgOM7UJSpcRbyus4duREF31xlzHV5T+A=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "1395379a7a36e40f2a76e7b9936cc52950baa1be", "rev": "58cef3796271aaeabaed98884d4abaab5d9d162d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -165,34 +165,6 @@
"type": "github" "type": "github"
} }
}, },
"ixx": {
"inputs": {
"flake-utils": [
"nixvim",
"nuschtosSearch",
"flake-utils"
],
"nixpkgs": [
"nixvim",
"nuschtosSearch",
"nixpkgs"
]
},
"locked": {
"lastModified": 1729958008,
"narHash": "sha256-EiOq8jF4Z/zQe0QYVc3+qSKxRK//CFHMB84aYrYGwEs=",
"owner": "NuschtOS",
"repo": "ixx",
"rev": "9fd01aad037f345350eab2cd45e1946cc66da4eb",
"type": "github"
},
"original": {
"owner": "NuschtOS",
"ref": "v0.0.6",
"repo": "ixx",
"type": "github"
}
},
"nix-darwin": { "nix-darwin": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@ -201,11 +173,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1733570843, "lastModified": 1722082646,
"narHash": "sha256-sQJAxY1TYWD1UyibN/FnN97paTFuwBw3Vp3DNCyKsMk=", "narHash": "sha256-od8dBWVP/ngg0cuoyEl/w9D+TCNDj6Kh4tr151Aax7w=",
"owner": "lnl7", "owner": "lnl7",
"repo": "nix-darwin", "repo": "nix-darwin",
"rev": "a35b08d09efda83625bef267eb24347b446c80b8", "rev": "0413754b3cdb879ba14f6e96915e5fdf06c6aab6",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -216,11 +188,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1734424634, "lastModified": 1722421184,
"narHash": "sha256-cHar1vqHOOyC7f1+tVycPoWTfKIaqkoe1Q6TnKzuti4=", "narHash": "sha256-/DJBI6trCeVnasdjUo9pbnodCLZcFqnVZiLUfqLH4jA=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "d3c42f187194c26d9f0309a8ecc469d6c878ce33", "rev": "9f918d616c5321ad374ae6cb5ea89c9e04bf3e58",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -232,23 +204,23 @@
}, },
"nixpkgs-lib": { "nixpkgs-lib": {
"locked": { "locked": {
"lastModified": 1733096140, "lastModified": 1722555339,
"narHash": "sha256-1qRH7uAUsyQI7R1Uwl4T+XvdNv778H0Nb5njNrqvylY=", "narHash": "sha256-uFf2QeW7eAHlYXuDktm9c25OxOyCoUOQmh5SZ9amE5Q=",
"type": "tarball", "type": "tarball",
"url": "https://github.com/NixOS/nixpkgs/archive/5487e69da40cbd611ab2cadee0b4637225f7cfae.tar.gz" "url": "https://github.com/NixOS/nixpkgs/archive/a5d394176e64ab29c852d03346c1fc9b0b7d33eb.tar.gz"
}, },
"original": { "original": {
"type": "tarball", "type": "tarball",
"url": "https://github.com/NixOS/nixpkgs/archive/5487e69da40cbd611ab2cadee0b4637225f7cfae.tar.gz" "url": "https://github.com/NixOS/nixpkgs/archive/a5d394176e64ab29c852d03346c1fc9b0b7d33eb.tar.gz"
} }
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1734424634, "lastModified": 1722185531,
"narHash": "sha256-cHar1vqHOOyC7f1+tVycPoWTfKIaqkoe1Q6TnKzuti4=", "narHash": "sha256-veKR07psFoJjINLC8RK4DiLniGGMgF3QMlS4tb74S6k=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "d3c42f187194c26d9f0309a8ecc469d6c878ce33", "rev": "52ec9ac3b12395ad677e8b62106f0b98c1f8569d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -271,11 +243,11 @@
"treefmt-nix": "treefmt-nix" "treefmt-nix": "treefmt-nix"
}, },
"locked": { "locked": {
"lastModified": 1734798432, "lastModified": 1722531900,
"narHash": "sha256-JVU+WjrRZUJnUKQ/iXP9O8eQ0L3YkqV1DpFMS4kLZog=", "narHash": "sha256-COtoy+Y/j2QLX818mRI7BweRJOltf0bndxbps/eoH0s=",
"owner": "nix-community", "owner": "nix-community",
"repo": "nixvim", "repo": "nixvim",
"rev": "6a4b4221c4ebf1140f73f8df769e97f1828d90fa", "rev": "7c39d77b9f1fbcbd8f2a575c4f2948dd54efc5c1",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -287,18 +259,17 @@
"nuschtosSearch": { "nuschtosSearch": {
"inputs": { "inputs": {
"flake-utils": "flake-utils", "flake-utils": "flake-utils",
"ixx": "ixx",
"nixpkgs": [ "nixpkgs": [
"nixvim", "nixvim",
"nixpkgs" "nixpkgs"
] ]
}, },
"locked": { "locked": {
"lastModified": 1733773348, "lastModified": 1722144272,
"narHash": "sha256-Y47y+LesOCkJaLvj+dI/Oa6FAKj/T9sKVKDXLNsViPw=", "narHash": "sha256-olZbfaEdd+zNPuuyYcYGaRzymA9rOmth8yXOlVm+LUs=",
"owner": "NuschtOS", "owner": "NuschtOS",
"repo": "search", "repo": "search",
"rev": "3051be7f403bff1d1d380e4612f0c70675b44fc9", "rev": "16565307c267ec219c2b5d3494ba66df08e7d403",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -337,11 +308,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1734704479, "lastModified": 1722330636,
"narHash": "sha256-MMi74+WckoyEWBRcg/oaGRvXC9BVVxDZNRMpL+72wBI=", "narHash": "sha256-uru7JzOa33YlSRwf9sfXpJG+UAV+bnBEYMjrzKrQZFw=",
"owner": "numtide", "owner": "numtide",
"repo": "treefmt-nix", "repo": "treefmt-nix",
"rev": "65712f5af67234dad91a5a4baee986a8b62dbf8f", "rev": "768acdb06968e53aa1ee8de207fd955335c754b7",
"type": "github" "type": "github"
}, },
"original": { "original": {