Compare commits
18 Commits
6a500118d9
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
| bcc5185ef4 | |||
| 50ffcb48e2 | |||
| 7f39cf1992 | |||
| 3ba1175ea9 | |||
| 24f67e2676 | |||
| 373cbf1815 | |||
| 71bf667d83 | |||
| 86428c0a28 | |||
| f5612d98c5 | |||
| 3c7ac8bf4e | |||
| 594ead9898 | |||
| 469864dd50 | |||
| 31fabb6b78 | |||
| 65d54f0c2e | |||
| 3d764647bd | |||
| 149b02f6a1 | |||
| 49e56875cd | |||
| 739c85b0bd |
@@ -1,6 +0,0 @@
|
||||
{
|
||||
plugins = {
|
||||
bufferline.enable = true;
|
||||
web-devicons.enable = true;
|
||||
};
|
||||
}
|
||||
43
config/cmp.nix
Normal file
43
config/cmp.nix
Normal file
@@ -0,0 +1,43 @@
|
||||
{ ... }: {
|
||||
|
||||
plugins = {
|
||||
|
||||
cmp-nvim-lsp.enable = true;
|
||||
|
||||
cmp = {
|
||||
enable = true;
|
||||
autoEnableSources = true;
|
||||
settings = {
|
||||
sources = [
|
||||
{ name = "nvim_lsp"; }
|
||||
{ name = "path"; }
|
||||
{ name = "buffer"; }
|
||||
{ name = "luasnip"; }
|
||||
# { name = "cmdline"; }
|
||||
];
|
||||
|
||||
completion = {
|
||||
completeopt = "menu,menuone,noinsert";
|
||||
};
|
||||
|
||||
mapping = {
|
||||
"<C-n>" = "cmp.mapping.select_next_item()";
|
||||
"<C-p>" = "cmp.mapping.select_prev_item()";
|
||||
"<C-y>" = "cmp.mapping.confirm({ select = true })";
|
||||
"<C-Space>" = "cmp.mapping.complete()";
|
||||
"<C-e>" = "cmp.mapping.abort()";
|
||||
"<C-b>" = "cmp.mapping.scroll_docs(-4)";
|
||||
"<C-f>" = "cmp.mapping.scroll_docs(4)";
|
||||
};
|
||||
|
||||
snippet.expand = ''
|
||||
function(args)
|
||||
require("luasnip").lsp_expand(args.body)
|
||||
end
|
||||
'';
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
};
|
||||
}
|
||||
116
config/dap.nix
Normal file
116
config/dap.nix
Normal file
@@ -0,0 +1,116 @@
|
||||
{ lib, pkgs, ... }: {
|
||||
|
||||
plugins = {
|
||||
|
||||
dap = {
|
||||
enable = true;
|
||||
|
||||
adapters = {
|
||||
executables = {
|
||||
lldb = {
|
||||
command = lib.getExe' pkgs.lldb "lldb-dap";
|
||||
};
|
||||
};
|
||||
|
||||
servers = {
|
||||
codelldb = {
|
||||
port = 13000;
|
||||
executable = {
|
||||
command = "${pkgs.vscode-extensions.vadimcn.vscode-lldb}/share/vscode/extensions/vadimcn.vscode-lldb/adapter/codelldb";
|
||||
args = [
|
||||
"--port"
|
||||
"13000"
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
configurations = let
|
||||
codelldb-config = {
|
||||
name = "Launch (CodeLLDB)";
|
||||
type = "codelldb";
|
||||
request = "launch";
|
||||
program.__raw = ''
|
||||
function()
|
||||
return vim.fn.input("Path to executable: ", vim.fn.getcwd() .. '/', "file")
|
||||
end
|
||||
'';
|
||||
cwd = ''''${workspaceFolder}'';
|
||||
stopOnEntry = false;
|
||||
};
|
||||
|
||||
lldb-config = {
|
||||
name = "Launch (LLDB)";
|
||||
type = "lldb";
|
||||
request = "launch";
|
||||
program.__raw = ''
|
||||
function()
|
||||
return vim.fn.input("Path to executable: ", vim.fn.getcwd() .. '/', "file")
|
||||
end'';
|
||||
cwd = ''''${workspaceFolder}'';
|
||||
stopOnEntry = false;
|
||||
};
|
||||
in {
|
||||
c = [ lldb-config ];
|
||||
|
||||
cpp =
|
||||
[ lldb-config ]
|
||||
++ lib.optionals pkgs.stdenv.isLinux [
|
||||
codelldb-config
|
||||
];
|
||||
|
||||
rust =
|
||||
[ lldb-config ]
|
||||
++ lib.optionals pkgs.stdenv.isLinux [
|
||||
codelldb-config
|
||||
];
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
dap-ui = {
|
||||
enable = true;
|
||||
|
||||
# Set icons to characters that are more likely to work in every terminal.
|
||||
# Feel free to remove or use ones that you like more! :)
|
||||
# Don't feel like these are good choices.
|
||||
settings = {
|
||||
icons = {
|
||||
expanded = "▾";
|
||||
collapsed = "▸";
|
||||
current_frame = "*";
|
||||
};
|
||||
|
||||
controls = {
|
||||
icons = {
|
||||
pause = "⏸";
|
||||
play = "▶";
|
||||
step_into = "⏎";
|
||||
step_over = "⏭";
|
||||
step_out = "⏮";
|
||||
step_back = "b";
|
||||
run_last = "▶▶";
|
||||
terminate = "⏹";
|
||||
disconnect = "⏏";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
dap-virtual-text.enable = true;
|
||||
|
||||
# Add debuggers here
|
||||
dap-python = {
|
||||
enable = true;
|
||||
adapterPythonPath = "python";
|
||||
};
|
||||
|
||||
|
||||
dap-lldb = {
|
||||
enable = true;
|
||||
settings.codelldb_path = "${pkgs.vscode-extensions.vadimcn.vscode-lldb}/share/vscode/extensions/vadimcn.vscode-lldb/adapter/codelldb";
|
||||
};
|
||||
|
||||
};
|
||||
}
|
||||
@@ -1,190 +1,18 @@
|
||||
{ pkgs, opts, ... }: {
|
||||
# Import all your configuration modules here
|
||||
imports = [ ./bufferline.nix ];
|
||||
|
||||
plugins = {
|
||||
|
||||
lualine.enable = true;
|
||||
|
||||
luasnip.enable = true;
|
||||
|
||||
barbar.enable = true;
|
||||
|
||||
nvim-tree.enable = true;
|
||||
|
||||
noice.enable = true;
|
||||
|
||||
mini.enable = true;
|
||||
|
||||
notify.enable = true;
|
||||
|
||||
telescope.enable = true;
|
||||
|
||||
treesitter.enable = true;
|
||||
|
||||
render-markdown.enable = true;
|
||||
|
||||
web-devicons.enable = true;
|
||||
|
||||
cmp-nvim-lsp.enable = true;
|
||||
|
||||
lsp = {
|
||||
enable = true;
|
||||
servers = {
|
||||
#js/typescript
|
||||
ts_ls.enable = true;
|
||||
#c/c++
|
||||
ccls.enable = true;
|
||||
#nix
|
||||
nil_ls.enable = true;
|
||||
#python
|
||||
pyright.enable = true;
|
||||
#bash
|
||||
bashls.enable = true;
|
||||
#css
|
||||
cssls.enable = true;
|
||||
|
||||
};
|
||||
|
||||
keymaps = {
|
||||
# Diagnostic keymaps
|
||||
diagnostic = {
|
||||
"<leader>q" = {
|
||||
#mode = "n";
|
||||
action = "setloclist";
|
||||
desc = "Open diagnostic [Q]uickfix list";
|
||||
};
|
||||
};
|
||||
|
||||
extra = [
|
||||
# Jump to the definition of the word under your cusor.
|
||||
# This is where a variable was first declared, or where a function is defined, etc.
|
||||
# To jump back, press <C-t>.
|
||||
{
|
||||
mode = "n";
|
||||
key = "gd";
|
||||
action.__raw = "require('telescope.builtin').lsp_definitions";
|
||||
options = {
|
||||
desc = "LSP: [G]oto [D]efinition";
|
||||
};
|
||||
}
|
||||
# Find references for the word under your cursor.
|
||||
{
|
||||
mode = "n";
|
||||
key = "gr";
|
||||
action.__raw = "require('telescope.builtin').lsp_references";
|
||||
options = {
|
||||
desc = "LSP: [G]oto [R]eferences";
|
||||
};
|
||||
}
|
||||
# Jump to the implementation of the word under your cursor.
|
||||
# Useful when your language has ways of declaring types without an actual implementation.
|
||||
{
|
||||
mode = "n";
|
||||
key = "gI";
|
||||
action.__raw = "require('telescope.builtin').lsp_implementations";
|
||||
options = {
|
||||
desc = "LSP: [G]oto [I]mplementation";
|
||||
};
|
||||
}
|
||||
# Jump to the type of the word under your cursor.
|
||||
# Useful when you're not sure what type a variable is and you want to see
|
||||
# the definition of its *type*, not where it was *defined*.
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>D";
|
||||
action.__raw = "require('telescope.builtin').lsp_type_definitions";
|
||||
options = {
|
||||
desc = "LSP: Type [D]efinition";
|
||||
};
|
||||
}
|
||||
# Fuzzy find all the symbols in your current document.
|
||||
# Symbols are things like variables, functions, types, etc.
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>ds";
|
||||
action.__raw = "require('telescope.builtin').lsp_document_symbols";
|
||||
options = {
|
||||
desc = "LSP: [D]ocument [S]ymbols";
|
||||
};
|
||||
}
|
||||
# Fuzzy find all the symbols in your current workspace.
|
||||
# Similar to document symbols, except searches over your entire project.
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>ws";
|
||||
action.__raw = "require('telescope.builtin').lsp_dynamic_workspace_symbols";
|
||||
options = {
|
||||
desc = "LSP: [W]orkspace [S]ymbols";
|
||||
};
|
||||
}
|
||||
imports = [
|
||||
./cmp.nix
|
||||
./dap.nix
|
||||
./lsp.nix
|
||||
./plugins.nix
|
||||
./keymaps.nix
|
||||
];
|
||||
|
||||
lspBuf = {
|
||||
# Rename the variable under your cursor.
|
||||
# Most Language Servers support renaming across files, etc.
|
||||
"<leader>rn" = {
|
||||
action = "rename";
|
||||
desc = "LSP: [R]e[n]ame";
|
||||
};
|
||||
# Execute a code action, usually your cursor needs to be on top of an error
|
||||
# or a suggestion from your LSP for this to activate.
|
||||
"<leader>ca" = {
|
||||
#mode = "n";
|
||||
action = "code_action";
|
||||
desc = "LSP: [C]ode [A]ction";
|
||||
};
|
||||
# WARN: This is not Goto Definition, this is Goto Declaration.
|
||||
# For example, in C this would take you to the header.
|
||||
"gD" = {
|
||||
action = "declaration";
|
||||
desc = "LSP: [G]oto [D]eclaration";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
cmp = {
|
||||
enable = true;
|
||||
autoEnableSources = true;
|
||||
settings = {
|
||||
sources = [
|
||||
{ name = "nvim_lsp"; }
|
||||
# { name = "path"; }
|
||||
# { name = "buffer"; }
|
||||
# { name = "luasnip"; }
|
||||
# { name = "cmdline"; }
|
||||
extraPackages = with pkgs; [
|
||||
coreutils
|
||||
lldb_18
|
||||
];
|
||||
|
||||
completion = {
|
||||
completeopt = "menu,menuone,noinsert";
|
||||
};
|
||||
|
||||
mapping = {
|
||||
"<C-n>" = "cmp.mapping.select_next_item()";
|
||||
"<C-p>" = "cmp.mapping.select_prev_item()";
|
||||
"<C-y>" = "cmp.mapping.confirm({ select = true })";
|
||||
"<C-Space>" = "cmp.mapping.complete()";
|
||||
"<C-e>" = "cmp.mapping.abort()";
|
||||
"<C-b>" = "cmp.mapping.scroll_docs(-4)";
|
||||
"<C-f>" = "cmp.mapping.scroll_docs(4)";
|
||||
};
|
||||
|
||||
snippet.expand = ''
|
||||
function(args)
|
||||
require("luasnip").lsp_expand(args.body)
|
||||
end
|
||||
'';
|
||||
};
|
||||
|
||||
};
|
||||
};
|
||||
|
||||
globals = {
|
||||
mapleader = " ";
|
||||
maplocalleader = " ";
|
||||
};
|
||||
|
||||
opts = {
|
||||
nu = true;
|
||||
rnu = true;
|
||||
@@ -204,102 +32,14 @@
|
||||
incsearch = true;
|
||||
};
|
||||
|
||||
keymaps = [
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>ff";
|
||||
action = "<cmd>Telescope find_files hidden=true<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>fc";
|
||||
action = "<cmd>Telescope treesitter<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>t";
|
||||
action = "<cmd>NvimTreeToggle<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<C-.>";
|
||||
action = "<cmd>BufferNext<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<C-,>";
|
||||
action = "<cmd>BufferPrevious<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<C-h>";
|
||||
action = "<cmd>wincmd h<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<C-j>";
|
||||
action = "<cmd>wincmd j<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<C-k>";
|
||||
action = "<cmd>wincmd k<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<C-l>";
|
||||
action = "<cmd>wincmd l<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "Q";
|
||||
action = "<nop>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "v";
|
||||
key = "J";
|
||||
action = ":m '>+1<CR>gv=gv";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "v";
|
||||
key = "K";
|
||||
action = ":m '<-2<CR>gv=gv";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>y";
|
||||
action = "\"+y";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "v";
|
||||
key = "<leader>y";
|
||||
action = "\"+y";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>s";
|
||||
action = ":%s/\\<<C-r><C-w>\\>/<C-r><C-w>/gI<Left><Left><Left>";
|
||||
}
|
||||
];
|
||||
|
||||
extraConfigLua = ''
|
||||
vim.filetype.add({
|
||||
pattern = { [".*/hypr/.*%.conf"] = "hyprlang" },
|
||||
})
|
||||
|
||||
require('dap').listeners.after.event_initialized['dapui_config'] = require('dapui').open
|
||||
require('dap').listeners.before.event_terminated['dapui_config'] = require('dapui').close
|
||||
require('dap').listeners.before.event_exited['dapui_config'] = require('dapui').close
|
||||
'';
|
||||
|
||||
extraPlugins = with pkgs.vimPlugins; [
|
||||
@@ -308,6 +48,8 @@
|
||||
llm-nvim
|
||||
nvim-lspconfig
|
||||
|
||||
nvim-treesitter-parsers.glsl
|
||||
|
||||
];
|
||||
|
||||
colorscheme = if opts.pywal then "pywal" else "tokyonight-storm";
|
||||
|
||||
188
config/keymaps.nix
Normal file
188
config/keymaps.nix
Normal file
@@ -0,0 +1,188 @@
|
||||
{ ... }: {
|
||||
|
||||
globals = {
|
||||
mapleader = " ";
|
||||
maplocalleader = " ";
|
||||
};
|
||||
|
||||
keymaps = [
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>ff";
|
||||
action = "<cmd>Telescope find_files hidden=true<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>fc";
|
||||
action = "<cmd>Telescope treesitter<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>t";
|
||||
action = "<cmd>NvimTreeToggle<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>.";
|
||||
action = "<cmd>BufferNext<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>,";
|
||||
action = "<cmd>BufferPrevious<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<C-h>";
|
||||
action = "<cmd>wincmd h<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<C-j>";
|
||||
action = "<cmd>wincmd j<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<C-k>";
|
||||
action = "<cmd>wincmd k<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<C-l>";
|
||||
action = "<cmd>wincmd l<CR>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "Q";
|
||||
action = "<nop>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "v";
|
||||
key = "J";
|
||||
action = ":m '>+1<CR>gv=gv";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "v";
|
||||
key = "K";
|
||||
action = ":m '<-2<CR>gv=gv";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>y";
|
||||
action = "\"+y";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "v";
|
||||
key = "<leader>y";
|
||||
action = "\"+y";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>s";
|
||||
action = ":%s/\\<<C-r><C-w>\\>/<C-r><C-w>/gI<Left><Left><Left>";
|
||||
}
|
||||
|
||||
{
|
||||
mode = "n";
|
||||
key = "<F5>";
|
||||
action.__raw = ''
|
||||
function()
|
||||
require('dap').continue()
|
||||
end
|
||||
'';
|
||||
options = {
|
||||
desc = "Debug: Start/Continue";
|
||||
};
|
||||
}
|
||||
{
|
||||
mode = "n";
|
||||
key = "<F1>";
|
||||
action.__raw = ''
|
||||
function()
|
||||
require('dap').step_into()
|
||||
end
|
||||
'';
|
||||
options = {
|
||||
desc = "Debug: Step Into";
|
||||
};
|
||||
}
|
||||
{
|
||||
mode = "n";
|
||||
key = "<F2>";
|
||||
action.__raw = ''
|
||||
function()
|
||||
require('dap').step_over()
|
||||
end
|
||||
'';
|
||||
options = {
|
||||
desc = "Debug: Step Over";
|
||||
};
|
||||
}
|
||||
{
|
||||
mode = "n";
|
||||
key = "<F3>";
|
||||
action.__raw = ''
|
||||
function()
|
||||
require('dap').step_out()
|
||||
end
|
||||
'';
|
||||
options = {
|
||||
desc = "Debug: Step Out";
|
||||
};
|
||||
}
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>b";
|
||||
action.__raw = ''
|
||||
function()
|
||||
require('dap').toggle_breakpoint()
|
||||
end
|
||||
'';
|
||||
options = {
|
||||
desc = "Debug: Toggle Breakpoint";
|
||||
};
|
||||
}
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>B";
|
||||
action.__raw = ''
|
||||
function()
|
||||
require('dap').set_breakpoint(vim.fn.input 'Breakpoint condition: ')
|
||||
end
|
||||
'';
|
||||
options = {
|
||||
desc = "Debug: Set Breakpoint";
|
||||
};
|
||||
}
|
||||
# Toggle to see last session result. Without this, you can't see session output
|
||||
# in case of unhandled exception.
|
||||
{
|
||||
mode = "n";
|
||||
key = "<F7>";
|
||||
action.__raw = ''
|
||||
function()
|
||||
require('dapui').toggle()
|
||||
end
|
||||
'';
|
||||
options = {
|
||||
desc = "Debug: See last session result.";
|
||||
};
|
||||
}
|
||||
];
|
||||
|
||||
|
||||
}
|
||||
144
config/lsp.nix
Normal file
144
config/lsp.nix
Normal file
@@ -0,0 +1,144 @@
|
||||
{ ... }: {
|
||||
|
||||
plugins = {
|
||||
lsp = {
|
||||
enable = true;
|
||||
servers = {
|
||||
#hyprlang
|
||||
hyprls.enable = true;
|
||||
#html
|
||||
html.enable = true;
|
||||
#js/typescript
|
||||
ts_ls.enable = true;
|
||||
#css
|
||||
cssls.enable = true;
|
||||
#c/c++
|
||||
ccls.enable = true;
|
||||
#nix
|
||||
nil_ls.enable = true;
|
||||
#python
|
||||
pyright.enable = true;
|
||||
#bash
|
||||
bashls.enable = true;
|
||||
#glsl
|
||||
glsl_analyzer.enable = true;
|
||||
#qml
|
||||
qmlls.enable = true;
|
||||
#ai
|
||||
/*lsp_ai = {
|
||||
enable = true;
|
||||
settings = {
|
||||
memory.file_store = {};
|
||||
models = {
|
||||
model1 = {
|
||||
type = "ollama";
|
||||
model = "llama3.2";
|
||||
};
|
||||
};
|
||||
chat = {};
|
||||
};
|
||||
};*/
|
||||
|
||||
};
|
||||
|
||||
keymaps = {
|
||||
# Diagnostic keymaps
|
||||
diagnostic = {
|
||||
"<leader>q" = {
|
||||
#mode = "n";
|
||||
action = "setloclist";
|
||||
desc = "Open diagnostic [Q]uickfix list";
|
||||
};
|
||||
};
|
||||
|
||||
extra = [
|
||||
# Jump to the definition of the word under your cusor.
|
||||
# This is where a variable was first declared, or where a function is defined, etc.
|
||||
# To jump back, press <C-t>.
|
||||
{
|
||||
mode = "n";
|
||||
key = "gd";
|
||||
action.__raw = "require('telescope.builtin').lsp_definitions";
|
||||
options = {
|
||||
desc = "LSP: [G]oto [D]efinition";
|
||||
};
|
||||
}
|
||||
# Find references for the word under your cursor.
|
||||
{
|
||||
mode = "n";
|
||||
key = "gr";
|
||||
action.__raw = "require('telescope.builtin').lsp_references";
|
||||
options = {
|
||||
desc = "LSP: [G]oto [R]eferences";
|
||||
};
|
||||
}
|
||||
# Jump to the implementation of the word under your cursor.
|
||||
# Useful when your language has ways of declaring types without an actual implementation.
|
||||
{
|
||||
mode = "n";
|
||||
key = "gI";
|
||||
action.__raw = "require('telescope.builtin').lsp_implementations";
|
||||
options = {
|
||||
desc = "LSP: [G]oto [I]mplementation";
|
||||
};
|
||||
}
|
||||
# Jump to the type of the word under your cursor.
|
||||
# Useful when you're not sure what type a variable is and you want to see
|
||||
# the definition of its *type*, not where it was *defined*.
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>D";
|
||||
action.__raw = "require('telescope.builtin').lsp_type_definitions";
|
||||
options = {
|
||||
desc = "LSP: Type [D]efinition";
|
||||
};
|
||||
}
|
||||
# Fuzzy find all the symbols in your current document.
|
||||
# Symbols are things like variables, functions, types, etc.
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>ds";
|
||||
action.__raw = "require('telescope.builtin').lsp_document_symbols";
|
||||
options = {
|
||||
desc = "LSP: [D]ocument [S]ymbols";
|
||||
};
|
||||
}
|
||||
# Fuzzy find all the symbols in your current workspace.
|
||||
# Similar to document symbols, except searches over your entire project.
|
||||
{
|
||||
mode = "n";
|
||||
key = "<leader>ws";
|
||||
action.__raw = "require('telescope.builtin').lsp_dynamic_workspace_symbols";
|
||||
options = {
|
||||
desc = "LSP: [W]orkspace [S]ymbols";
|
||||
};
|
||||
}
|
||||
];
|
||||
|
||||
lspBuf = {
|
||||
# Rename the variable under your cursor.
|
||||
# Most Language Servers support renaming across files, etc.
|
||||
"<leader>rn" = {
|
||||
action = "rename";
|
||||
desc = "LSP: [R]e[n]ame";
|
||||
};
|
||||
# Execute a code action, usually your cursor needs to be on top of an error
|
||||
# or a suggestion from your LSP for this to activate.
|
||||
"<leader>ca" = {
|
||||
#mode = "n";
|
||||
action = "code_action";
|
||||
desc = "LSP: [C]ode [A]ction";
|
||||
};
|
||||
# WARN: This is not Goto Definition, this is Goto Declaration.
|
||||
# For example, in C this would take you to the header.
|
||||
"gD" = {
|
||||
action = "declaration";
|
||||
desc = "LSP: [G]oto [D]eclaration";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
38
config/plugins.nix
Normal file
38
config/plugins.nix
Normal file
@@ -0,0 +1,38 @@
|
||||
{ pkgs, ... }: {
|
||||
|
||||
plugins = {
|
||||
|
||||
lualine.enable = true;
|
||||
|
||||
luasnip.enable = true;
|
||||
|
||||
barbar.enable = true;
|
||||
|
||||
nvim-tree.enable = true;
|
||||
|
||||
noice.enable = true;
|
||||
|
||||
mini.enable = true;
|
||||
|
||||
notify.enable = true;
|
||||
|
||||
telescope.enable = true;
|
||||
|
||||
treesitter = {
|
||||
enable = true;
|
||||
settings = {
|
||||
highlight.enable = true;
|
||||
grammarPackages = pkgs.vimPlugins.nvim-treesitter.passthru.allGrammars ++ [
|
||||
pkgs.vimPlugins.nvim-treesitter-parsers.glsl
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
render-markdown.enable = true;
|
||||
|
||||
web-devicons.enable = true;
|
||||
|
||||
bufferline.enable = true;
|
||||
};
|
||||
|
||||
}
|
||||
219
flake.lock
generated
219
flake.lock
generated
@@ -1,50 +1,15 @@
|
||||
{
|
||||
"nodes": {
|
||||
"devshell": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixvim",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1728330715,
|
||||
"narHash": "sha256-xRJ2nPOXb//u1jaBnDP56M7v5ldavjbtR6lfGqSvcKg=",
|
||||
"owner": "numtide",
|
||||
"repo": "devshell",
|
||||
"rev": "dd6b80932022cea34a019e2bb32f6fa9e494dfef",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "devshell",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-compat": {
|
||||
"locked": {
|
||||
"lastModified": 1696426674,
|
||||
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
|
||||
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
|
||||
"revCount": 57,
|
||||
"type": "tarball",
|
||||
"url": "https://api.flakehub.com/f/pinned/edolstra/flake-compat/1.0.1/018afb31-abd1-7bff-a5e4-cff7e18efb7a/source.tar.gz"
|
||||
},
|
||||
"original": {
|
||||
"type": "tarball",
|
||||
"url": "https://flakehub.com/f/edolstra/flake-compat/1.tar.gz"
|
||||
}
|
||||
},
|
||||
"flake-parts": {
|
||||
"inputs": {
|
||||
"nixpkgs-lib": "nixpkgs-lib"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1730504689,
|
||||
"narHash": "sha256-hgmguH29K2fvs9szpq2r3pz2/8cJd2LPS+b4tfNFCwE=",
|
||||
"lastModified": 1754487366,
|
||||
"narHash": "sha256-pHYj8gUBapuUzKV/kN/tR3Zvqc7o6gdFB9XKXIp1SQ8=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"rev": "506278e768c2a08bec68eb62932193e341f55c90",
|
||||
"rev": "af66ad14b28a127c5c0f3bbb298218fc63528a18",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -61,11 +26,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1730504689,
|
||||
"narHash": "sha256-hgmguH29K2fvs9szpq2r3pz2/8cJd2LPS+b4tfNFCwE=",
|
||||
"lastModified": 1754487366,
|
||||
"narHash": "sha256-pHYj8gUBapuUzKV/kN/tR3Zvqc7o6gdFB9XKXIp1SQ8=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"rev": "506278e768c2a08bec68eb62932193e341f55c90",
|
||||
"rev": "af66ad14b28a127c5c0f3bbb298218fc63528a18",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -92,79 +57,6 @@
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"git-hooks": {
|
||||
"inputs": {
|
||||
"flake-compat": [
|
||||
"nixvim",
|
||||
"flake-compat"
|
||||
],
|
||||
"gitignore": "gitignore",
|
||||
"nixpkgs": [
|
||||
"nixvim",
|
||||
"nixpkgs"
|
||||
],
|
||||
"nixpkgs-stable": [
|
||||
"nixvim",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1731363552,
|
||||
"narHash": "sha256-vFta1uHnD29VUY4HJOO/D6p6rxyObnf+InnSMT4jlMU=",
|
||||
"owner": "cachix",
|
||||
"repo": "git-hooks.nix",
|
||||
"rev": "cd1af27aa85026ac759d5d3fccf650abe7e1bbf0",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "cachix",
|
||||
"repo": "git-hooks.nix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"gitignore": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixvim",
|
||||
"git-hooks",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1709087332,
|
||||
"narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "gitignore.nix",
|
||||
"rev": "637db329424fd7e46cf4185293b9cc8c88c95394",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hercules-ci",
|
||||
"repo": "gitignore.nix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixvim",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1731887066,
|
||||
"narHash": "sha256-uw7K/RsYioJicV79Nl39yjtfhdfTDU2aRxnBgvFhkZ8=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "f3a2ff69586f3a54b461526e5702b1a2f81e740a",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"ixx": {
|
||||
"inputs": {
|
||||
"flake-utils": [
|
||||
@@ -179,48 +71,27 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1729958008,
|
||||
"narHash": "sha256-EiOq8jF4Z/zQe0QYVc3+qSKxRK//CFHMB84aYrYGwEs=",
|
||||
"lastModified": 1754860581,
|
||||
"narHash": "sha256-EM0IE63OHxXCOpDHXaTyHIOk2cNvMCGPqLt/IdtVxgk=",
|
||||
"owner": "NuschtOS",
|
||||
"repo": "ixx",
|
||||
"rev": "9fd01aad037f345350eab2cd45e1946cc66da4eb",
|
||||
"rev": "babfe85a876162c4acc9ab6fb4483df88fa1f281",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NuschtOS",
|
||||
"ref": "v0.0.6",
|
||||
"ref": "v0.1.1",
|
||||
"repo": "ixx",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nix-darwin": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixvim",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1731885500,
|
||||
"narHash": "sha256-ZrztYfSOS33J+ewq5alBOSdnIyZ0/sr1iy7FyBe9zIg=",
|
||||
"owner": "lnl7",
|
||||
"repo": "nix-darwin",
|
||||
"rev": "c60b5c924c6188a0b3ca2e139ead3d0f92ae5db5",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "lnl7",
|
||||
"repo": "nix-darwin",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1731676054,
|
||||
"narHash": "sha256-OZiZ3m8SCMfh3B6bfGC/Bm4x3qc1m2SVEAlkV6iY7Yg=",
|
||||
"lastModified": 1755615617,
|
||||
"narHash": "sha256-HMwfAJBdrr8wXAkbGhtcby1zGFvs+StOp19xNsbqdOg=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "5e4fbfb6b3de1aa2872b76d49fafc942626e2add",
|
||||
"rev": "20075955deac2583bb12f07151c2df830ef346b4",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -232,50 +103,48 @@
|
||||
},
|
||||
"nixpkgs-lib": {
|
||||
"locked": {
|
||||
"lastModified": 1730504152,
|
||||
"narHash": "sha256-lXvH/vOfb4aGYyvFmZK/HlsNsr/0CVWlwYvo2rxJk3s=",
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/NixOS/nixpkgs/archive/cc2f28000298e1269cea6612cd06ec9979dd5d7f.tar.gz"
|
||||
"lastModified": 1753579242,
|
||||
"narHash": "sha256-zvaMGVn14/Zz8hnp4VWT9xVnhc8vuL3TStRqwk22biA=",
|
||||
"owner": "nix-community",
|
||||
"repo": "nixpkgs.lib",
|
||||
"rev": "0f36c44e01a6129be94e3ade315a5883f0228a6e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/NixOS/nixpkgs/archive/cc2f28000298e1269cea6612cd06ec9979dd5d7f.tar.gz"
|
||||
"owner": "nix-community",
|
||||
"repo": "nixpkgs.lib",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1731676054,
|
||||
"narHash": "sha256-OZiZ3m8SCMfh3B6bfGC/Bm4x3qc1m2SVEAlkV6iY7Yg=",
|
||||
"lastModified": 1755577059,
|
||||
"narHash": "sha256-5hYhxIpco8xR+IpP3uU56+4+Bw7mf7EMyxS/HqUYHQY=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "5e4fbfb6b3de1aa2872b76d49fafc942626e2add",
|
||||
"rev": "97eb7ee0da337d385ab015a23e15022c865be75c",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-unstable",
|
||||
"ref": "nixpkgs-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixvim": {
|
||||
"inputs": {
|
||||
"devshell": "devshell",
|
||||
"flake-compat": "flake-compat",
|
||||
"flake-parts": "flake-parts_2",
|
||||
"git-hooks": "git-hooks",
|
||||
"home-manager": "home-manager",
|
||||
"nix-darwin": "nix-darwin",
|
||||
"nixpkgs": "nixpkgs_2",
|
||||
"nuschtosSearch": "nuschtosSearch",
|
||||
"treefmt-nix": "treefmt-nix"
|
||||
"systems": "systems_2"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1732035679,
|
||||
"narHash": "sha256-J03v1XnxvsrrvHmzKVBZiwik8678IXfkH1/ZR954ujk=",
|
||||
"lastModified": 1755741137,
|
||||
"narHash": "sha256-YnpE/fOL3H8cJZ9by/YmeNhIqOQdKuZRYA1L3+w6WsI=",
|
||||
"owner": "nix-community",
|
||||
"repo": "nixvim",
|
||||
"rev": "929bb0cd1cffb9917ab14be9cdb3f27efd6f505f",
|
||||
"rev": "91a38e66240c338e683421a4ee3f525d329fc4ad",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -294,11 +163,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1731936508,
|
||||
"narHash": "sha256-z0BSSf78LkxIrrFXZYmCoRRAxAmxMUKpK7CyxQRvkZI=",
|
||||
"lastModified": 1755555503,
|
||||
"narHash": "sha256-WiOO7GUOsJ4/DoMy2IC5InnqRDSo2U11la48vCCIjjY=",
|
||||
"owner": "NuschtOS",
|
||||
"repo": "search",
|
||||
"rev": "fe07070f811b717a4626d01fab714a87d422a9e1",
|
||||
"rev": "6f3efef888b92e6520f10eae15b86ff537e1d2ea",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -329,24 +198,18 @@
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"treefmt-nix": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixvim",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"systems_2": {
|
||||
"locked": {
|
||||
"lastModified": 1731944360,
|
||||
"narHash": "sha256-sJxPh+V0vUkBhlA58ok/y0o96AtfqiEF0O8qsdolI6o=",
|
||||
"owner": "numtide",
|
||||
"repo": "treefmt-nix",
|
||||
"rev": "579b9a2fd0020cd9cd81a4ef4eab2dca4d20c94c",
|
||||
"lastModified": 1681028828,
|
||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "treefmt-nix",
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"type": "github"
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user