This commit is contained in:
commit
30ce0dafc2
195 changed files with 8902 additions and 0 deletions
12
users/macan/modules/nvf/assistant.nix
Normal file
12
users/macan/modules/nvf/assistant.nix
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
{
|
||||
programs.nvf.settings.vim.assistant.neocodeium = {
|
||||
enable = true;
|
||||
setupOpts = {
|
||||
enabled = true;
|
||||
log_level = "debug";
|
||||
};
|
||||
keymaps = {
|
||||
accept = "<A-Tab>";
|
||||
};
|
||||
};
|
||||
}
|
||||
31
users/macan/modules/nvf/default.nix
Normal file
31
users/macan/modules/nvf/default.nix
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
{
|
||||
inputs,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
inputs.nvf.homeManagerModules.default
|
||||
./assistant.nix
|
||||
./options.nix
|
||||
./languages.nix
|
||||
./picker.nix
|
||||
./snacks.nix
|
||||
./keymaps.nix
|
||||
./utils.nix
|
||||
./mini.nix
|
||||
];
|
||||
|
||||
home.packages = with pkgs; [
|
||||
neovim
|
||||
];
|
||||
|
||||
programs.nvf = {
|
||||
enable = true;
|
||||
settings.vim = {
|
||||
startPlugins = [
|
||||
pkgs.vimPlugins.vim-kitty-navigator
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
269
users/macan/modules/nvf/keymaps.nix
Normal file
269
users/macan/modules/nvf/keymaps.nix
Normal file
|
|
@ -0,0 +1,269 @@
|
|||
{
|
||||
programs.nvf.settings.vim = {
|
||||
globals.mapleader = " ";
|
||||
binds = {
|
||||
whichKey = {
|
||||
enable = true;
|
||||
register = { };
|
||||
};
|
||||
};
|
||||
keymaps = [
|
||||
# "hjkl" -> "jkl;"
|
||||
{
|
||||
mode = "n"; # Normal mode
|
||||
key = "j";
|
||||
action = "<Left>";
|
||||
desc = "Move Left";
|
||||
}
|
||||
{
|
||||
mode = "n";
|
||||
key = "k";
|
||||
action = "<Down>";
|
||||
desc = "Move Down";
|
||||
}
|
||||
{
|
||||
mode = "n";
|
||||
key = "l";
|
||||
action = "<Up>";
|
||||
desc = "Move Up";
|
||||
}
|
||||
{
|
||||
mode = "n";
|
||||
key = ";";
|
||||
action = "<Right>";
|
||||
desc = "Move Right";
|
||||
}
|
||||
{
|
||||
mode = "v"; # Visual mode
|
||||
key = "j";
|
||||
action = "<Left>";
|
||||
desc = "Move Left";
|
||||
}
|
||||
{
|
||||
mode = "v";
|
||||
key = "k";
|
||||
action = "<Down>";
|
||||
desc = "Move Down";
|
||||
}
|
||||
{
|
||||
mode = "v";
|
||||
key = "l";
|
||||
action = "<Up>";
|
||||
desc = "Move Up";
|
||||
}
|
||||
{
|
||||
mode = "v";
|
||||
key = ";";
|
||||
action = "<Right>";
|
||||
desc = "Move Right";
|
||||
}
|
||||
|
||||
# General Mappings
|
||||
{
|
||||
key = "s";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua require('flash').jump()<cr>";
|
||||
desc = "Flash";
|
||||
}
|
||||
{
|
||||
key = "K";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua vim.lsp.buf.hover()<cr>";
|
||||
desc = "LSP Hover";
|
||||
}
|
||||
{
|
||||
key = "<C-tab>";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>bnext<cr>";
|
||||
desc = "Next Buffer";
|
||||
}
|
||||
{
|
||||
key = "rn";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua vim.lsp.buf.rename()<cr>";
|
||||
desc = "Rename symbol";
|
||||
}
|
||||
|
||||
# Escape from Insert Mode
|
||||
{
|
||||
key = "jj";
|
||||
mode = "i";
|
||||
action = "<Esc>";
|
||||
desc = "Exit insert mode";
|
||||
} # UI
|
||||
{
|
||||
key = "<leader>uw";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>set wrap!<cr>";
|
||||
desc = "Toggle word wrapping";
|
||||
}
|
||||
{
|
||||
key = "<leader>ul";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>set linebreak!<cr>";
|
||||
desc = "Toggle linebreak";
|
||||
}
|
||||
{
|
||||
key = "<leader>us";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>set spell!<cr>";
|
||||
desc = "Toggle spellLazyGitcheck";
|
||||
}
|
||||
{
|
||||
key = "<leader>uc";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>set cursorline!<cr>";
|
||||
desc = "Toggle cursorline";
|
||||
}
|
||||
{
|
||||
key = "<leader>un";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>set number!<cr>";
|
||||
desc = "Toggle line numbers";
|
||||
}
|
||||
{
|
||||
key = "<leader>ur";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>set relativenumber!<cr>";
|
||||
desc = "Toggle relative line numbers";
|
||||
}
|
||||
{
|
||||
key = "<leader>ut";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>set showtabline=2<cr>";
|
||||
desc = "Show tabline";
|
||||
}
|
||||
{
|
||||
key = "<leader>uT";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>set showtabline=0<cr>";
|
||||
desc = "Hide tabline";
|
||||
}
|
||||
|
||||
# Windows
|
||||
{
|
||||
key = "<leader>ws";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>split<cr>";
|
||||
desc = "Split";
|
||||
}
|
||||
{
|
||||
key = "<leader>wv";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>vsplit<cr>";
|
||||
desc = "VSplit";
|
||||
}
|
||||
{
|
||||
key = "<leader>wd";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>close<cr>";
|
||||
desc = "Close";
|
||||
}
|
||||
|
||||
# Disable Arrow Keys in Normal Mode
|
||||
{
|
||||
key = "<Up>";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<Nop>";
|
||||
desc = "Disable Up Arrow";
|
||||
}
|
||||
{
|
||||
key = "<Down>";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<Nop>";
|
||||
desc = "Disable Down Arrow";
|
||||
}
|
||||
{
|
||||
key = "<Left>";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<Nop>";
|
||||
desc = "Disable Left Arrow";
|
||||
}
|
||||
{
|
||||
key = "<Right>";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<Nop>";
|
||||
desc = "Disable Right Arrow";
|
||||
}
|
||||
|
||||
# Disable Arrow Keys in Visual Mode
|
||||
{
|
||||
key = "<Up>";
|
||||
mode = "v";
|
||||
silent = true;
|
||||
action = "<Nop>";
|
||||
desc = "Disable Up Arrow";
|
||||
}
|
||||
{
|
||||
key = "<Down>";
|
||||
mode = "v";
|
||||
silent = true;
|
||||
action = "<Nop>";
|
||||
desc = "Disable Down Arrow";
|
||||
}
|
||||
{
|
||||
key = "<Left>";
|
||||
mode = "v";
|
||||
silent = true;
|
||||
action = "<Nop>";
|
||||
desc = "Disable Left Arrow";
|
||||
}
|
||||
{
|
||||
key = "<Right>";
|
||||
mode = "v";
|
||||
silent = true;
|
||||
action = "<Nop>";
|
||||
desc = "Disable Right Arrow";
|
||||
}
|
||||
|
||||
# Disable Arrow Keys in Insert Mode
|
||||
{
|
||||
key = "<Up>";
|
||||
mode = "i";
|
||||
silent = true;
|
||||
action = "<Nop>";
|
||||
desc = "Disable Up Arrow";
|
||||
}
|
||||
{
|
||||
key = "<Down>";
|
||||
mode = "i";
|
||||
silent = true;
|
||||
action = "<Nop>";
|
||||
desc = "Disable Down Arrow";
|
||||
}
|
||||
{
|
||||
key = "<Left>";
|
||||
mode = "i";
|
||||
silent = true;
|
||||
action = "<Nop>";
|
||||
desc = "Disable Left Arrow";
|
||||
}
|
||||
{
|
||||
key = "<Right>";
|
||||
mode = "i";
|
||||
silent = true;
|
||||
action = "<Nop>";
|
||||
desc = "Disable Right Arrow";
|
||||
}
|
||||
];
|
||||
};
|
||||
}
|
||||
122
users/macan/modules/nvf/languages.nix
Normal file
122
users/macan/modules/nvf/languages.nix
Normal file
|
|
@ -0,0 +1,122 @@
|
|||
{ lib, ... }:
|
||||
{
|
||||
programs.nvf.settings.vim = {
|
||||
diagnostics = {
|
||||
enable = true;
|
||||
config = {
|
||||
signs = {
|
||||
text = {
|
||||
"vim.diagnostic.severity.Error" = " ";
|
||||
"vim.diagnostic.severity.Warn" = " ";
|
||||
"vim.diagnostic.severity.Hint" = " ";
|
||||
"vim.diagnostic.severity.Info" = " ";
|
||||
};
|
||||
};
|
||||
underline = true;
|
||||
update_in_insert = true;
|
||||
virtual_text = {
|
||||
format =
|
||||
lib.generators.mkLuaInline
|
||||
# lua
|
||||
''
|
||||
function(diagnostic)
|
||||
return string.format("%s", diagnostic.message)
|
||||
--return string.format("%s (%s)", diagnostic.message, diagnostic.source)
|
||||
end
|
||||
'';
|
||||
};
|
||||
};
|
||||
nvim-lint = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
syntaxHighlighting = true;
|
||||
treesitter = {
|
||||
enable = true;
|
||||
autotagHtml = true;
|
||||
context.enable = true;
|
||||
highlight.enable = true;
|
||||
};
|
||||
lsp = {
|
||||
enable = true;
|
||||
trouble.enable = true;
|
||||
lspSignature.enable = true;
|
||||
lspconfig.enable = true;
|
||||
formatOnSave = true;
|
||||
inlayHints.enable = true;
|
||||
null-ls.enable = true;
|
||||
otter-nvim = {
|
||||
enable = true;
|
||||
setupOpts = {
|
||||
buffers.set_filetype = true;
|
||||
lsp = {
|
||||
diagnostic_update_event = [
|
||||
"BufWritePost"
|
||||
"InsertLeave"
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
lspkind.enable = true;
|
||||
lspsaga = {
|
||||
enable = true;
|
||||
setupOpts = {
|
||||
ui = {
|
||||
code_action = "";
|
||||
};
|
||||
lightbulb = {
|
||||
sign = false;
|
||||
virtual_text = true;
|
||||
};
|
||||
breadcrumbs.enable = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
languages = {
|
||||
enableDAP = true;
|
||||
enableExtraDiagnostics = true;
|
||||
enableFormat = true;
|
||||
enableTreesitter = true;
|
||||
|
||||
bash.enable = true;
|
||||
clang.enable = true;
|
||||
css.enable = true;
|
||||
elixir.enable = true;
|
||||
go.enable = true;
|
||||
html.enable = true;
|
||||
json.enable = true;
|
||||
lua.enable = true;
|
||||
markdown = {
|
||||
enable = true;
|
||||
extensions = {
|
||||
render-markdown-nvim = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
extraDiagnostics.enable = true;
|
||||
};
|
||||
nim.enable = true;
|
||||
nix.enable = true;
|
||||
python = {
|
||||
enable = true;
|
||||
format.type = [
|
||||
"black"
|
||||
"isort"
|
||||
];
|
||||
};
|
||||
rust.enable = true;
|
||||
tailwind.enable = true;
|
||||
ts = {
|
||||
enable = true;
|
||||
extensions.ts-error-translator.enable = true;
|
||||
};
|
||||
yaml.enable = true;
|
||||
zig.enable = true;
|
||||
};
|
||||
formatter = {
|
||||
conform-nvim = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
13
users/macan/modules/nvf/mini.nix
Normal file
13
users/macan/modules/nvf/mini.nix
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
{
|
||||
programs.nvf.settings.vim.mini = {
|
||||
starter.enable = true;
|
||||
comment.enable = true;
|
||||
# cursorword.enable = true;
|
||||
icons.enable = true;
|
||||
indentscope.enable = true;
|
||||
notify.enable = true;
|
||||
pairs.enable = true;
|
||||
diff.enable = true;
|
||||
git.enable = true;
|
||||
};
|
||||
}
|
||||
41
users/macan/modules/nvf/options.nix
Normal file
41
users/macan/modules/nvf/options.nix
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
{ lib, ... }:
|
||||
{
|
||||
programs.nvf.settings.vim = {
|
||||
viAlias = false;
|
||||
vimAlias = true;
|
||||
withNodeJs = true;
|
||||
# syntaxHighlighting = true;
|
||||
options = {
|
||||
autoindent = true;
|
||||
smartindent = true;
|
||||
shiftwidth = 2;
|
||||
foldlevel = 99;
|
||||
foldcolumn = "auto:1";
|
||||
mousescroll = "ver:1,hor:1";
|
||||
mousemoveevent = true;
|
||||
fillchars = "eob:‿,fold: ,foldopen:▼,foldsep:⸽,foldclose:⏵";
|
||||
signcolumn = "yes";
|
||||
tabstop = 2;
|
||||
softtabstop = 2;
|
||||
wrap = false;
|
||||
};
|
||||
globals = {
|
||||
navic_silence = true; # navic tries to attach multiple LSPs and fails
|
||||
suda_smart_edit = 1; # use super user write automatically
|
||||
neovide_scale_factor = 0.7;
|
||||
neovide_cursor_animation_length = 0.1;
|
||||
neovide_cursor_short_animation_length = 0;
|
||||
};
|
||||
clipboard = {
|
||||
enable = true;
|
||||
registers = "unnamedplus";
|
||||
providers.wl-copy.enable = true;
|
||||
};
|
||||
theme = {
|
||||
enable = true;
|
||||
name = lib.mkForce "catppuccin";
|
||||
style = lib.mkForce "mocha";
|
||||
transparent = lib.mkForce true;
|
||||
};
|
||||
};
|
||||
}
|
||||
256
users/macan/modules/nvf/picker.nix
Normal file
256
users/macan/modules/nvf/picker.nix
Normal file
|
|
@ -0,0 +1,256 @@
|
|||
{
|
||||
programs.nvf.settings.vim = {
|
||||
utility = {
|
||||
oil-nvim.enable = true;
|
||||
snacks-nvim = {
|
||||
setupOpts = {
|
||||
picker.enabled = true;
|
||||
explorer.enabled = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
keymaps = [
|
||||
# Top Pickers & Explorer
|
||||
{
|
||||
key = "<leader> ";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.smart()<cr>";
|
||||
desc = "Smart Find Files";
|
||||
}
|
||||
{
|
||||
key = "<leader>,";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.buffers()<cr>";
|
||||
desc = "Buffers";
|
||||
}
|
||||
{
|
||||
key = "<leader>/";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.grep()<cr>";
|
||||
desc = "Grep";
|
||||
}
|
||||
{
|
||||
key = "<leader>:";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.command_history()<cr>";
|
||||
desc = "Command History";
|
||||
}
|
||||
{
|
||||
key = "<leader>e";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.explorer()<cr>";
|
||||
desc = "File Explorer";
|
||||
}
|
||||
{
|
||||
key = "-";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>Oil<cr>";
|
||||
desc = "Oil";
|
||||
}
|
||||
|
||||
# Find
|
||||
{
|
||||
key = "<leader>fb";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.buffers()<cr>";
|
||||
desc = "Buffers";
|
||||
}
|
||||
{
|
||||
key = "<leader>fc";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = ''<cmd>lua Snacks.picker.files({ cwd = vim.fn.stdpath("config") })<cr>'';
|
||||
desc = "Find Config File";
|
||||
}
|
||||
{
|
||||
key = "<leader>ff";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.files()<cr>";
|
||||
desc = "Find Files";
|
||||
}
|
||||
{
|
||||
key = "<leader>fg";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.git_files()<cr>";
|
||||
desc = "Find Git Files";
|
||||
}
|
||||
{
|
||||
key = "<leader>fp";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.projects()<cr>";
|
||||
desc = "Projects";
|
||||
}
|
||||
{
|
||||
key = "<leader>fr";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.recent()<cr>";
|
||||
desc = "Recent";
|
||||
}
|
||||
{
|
||||
key = "<leader>fn";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.notifications()<cr>";
|
||||
desc = "Notification History";
|
||||
}
|
||||
{
|
||||
key = "<leader>fe";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.icons()<cr>";
|
||||
desc = "Emoji";
|
||||
}
|
||||
|
||||
# Git
|
||||
{
|
||||
key = "<leader>gb";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.git_branches()<cr>";
|
||||
desc = "Git Branches";
|
||||
}
|
||||
{
|
||||
key = "<leader>gL";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.git_log()<cr>";
|
||||
desc = "Git Log Line";
|
||||
}
|
||||
{
|
||||
key = "<leader>gs";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.git_status()<cr>";
|
||||
desc = "Git Status";
|
||||
}
|
||||
{
|
||||
key = "<leader>gS";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.git_stash()<cr>";
|
||||
desc = "Git Stash";
|
||||
}
|
||||
{
|
||||
key = "<leader>gd";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.git_diff()<cr>";
|
||||
desc = "Git Diff (Hunks)";
|
||||
}
|
||||
{
|
||||
key = "<leader>gf";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.git_log_file()<cr>";
|
||||
desc = "Git Log File";
|
||||
}
|
||||
|
||||
# Grep
|
||||
{
|
||||
key = "<leader>sb";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.lines()<cr>";
|
||||
desc = "Buffer Lines";
|
||||
}
|
||||
{
|
||||
key = "<leader>st";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.todo_comments()<cr>";
|
||||
desc = "Todos";
|
||||
}
|
||||
{
|
||||
key = "<leader>sB";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.grep_buffers()<cr>";
|
||||
desc = "Grep Open Buffers";
|
||||
}
|
||||
{
|
||||
key = "<leader>sg";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.grep()<cr>";
|
||||
desc = "Grep";
|
||||
}
|
||||
{
|
||||
key = "<leader>sw";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.grep_word()<cr>";
|
||||
desc = "Visual selection or word";
|
||||
}
|
||||
{
|
||||
key = "<leader>sr";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>nohlsearch<cr>";
|
||||
desc = "Reset search";
|
||||
}
|
||||
|
||||
# LSP
|
||||
{
|
||||
key = "gd";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.lsp_definitions()<cr>";
|
||||
desc = "Goto Definition";
|
||||
}
|
||||
{
|
||||
key = "gD";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.lsp_declarations()<cr>";
|
||||
desc = "Goto Declaration";
|
||||
}
|
||||
{
|
||||
key = "gr";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.lsp_references()<cr>";
|
||||
desc = "References";
|
||||
nowait = true;
|
||||
}
|
||||
{
|
||||
key = "gI";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.lsp_implementations()<cr>";
|
||||
desc = "Goto Implementation";
|
||||
}
|
||||
{
|
||||
key = "gy";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.lsp_type_definitions()<cr>";
|
||||
desc = "Goto Type Definition";
|
||||
}
|
||||
{
|
||||
key = "<leader>ss";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.lsp_symbols()<cr>";
|
||||
desc = "LSP Symbols";
|
||||
}
|
||||
{
|
||||
key = "<leader>sS";
|
||||
mode = "n";
|
||||
silent = true;
|
||||
action = "<cmd>lua Snacks.picker.lsp_workspace_symbols()<cr>";
|
||||
desc = "LSP Workspace Symbols";
|
||||
}
|
||||
];
|
||||
};
|
||||
}
|
||||
16
users/macan/modules/nvf/snacks.nix
Normal file
16
users/macan/modules/nvf/snacks.nix
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
{
|
||||
programs.nvf.settings.vim.utility.snacks-nvim = {
|
||||
enable = true;
|
||||
setupOpts = {
|
||||
image = {
|
||||
enabled = true;
|
||||
setupOpts.doc.inline = false;
|
||||
};
|
||||
quickfile.enabled = true;
|
||||
statuscolumn.enabled = true;
|
||||
zen.enabled = true;
|
||||
bufdelete.enabled = true;
|
||||
gitsigns.enabled = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
50
users/macan/modules/nvf/utils.nix
Normal file
50
users/macan/modules/nvf/utils.nix
Normal file
|
|
@ -0,0 +1,50 @@
|
|||
{ pkgs, ... }:
|
||||
{
|
||||
programs.nvf.settings.vim = {
|
||||
undoFile.enable = true;
|
||||
utility = {
|
||||
motion.flash-nvim.enable = true;
|
||||
outline.aerial-nvim.enable = true;
|
||||
};
|
||||
tabline.nvimBufferline.enable = true;
|
||||
notes.todo-comments.enable = true;
|
||||
statusline.lualine.enable = true;
|
||||
|
||||
autocomplete = {
|
||||
nvim-cmp = {
|
||||
enable = true;
|
||||
sources = {
|
||||
buffer = "[Buffer]";
|
||||
nvim-cmp = null;
|
||||
path = "[Path]";
|
||||
};
|
||||
sourcePlugins = [
|
||||
pkgs.vimPlugins.cmp-cmdline
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
snippets.luasnip.enable = true;
|
||||
ui = {
|
||||
noice.enable = true;
|
||||
colorizer.enable = true;
|
||||
};
|
||||
git = {
|
||||
enable = true;
|
||||
gitsigns.enable = true;
|
||||
};
|
||||
terminal.toggleterm = {
|
||||
enable = true;
|
||||
lazygit = {
|
||||
enable = true;
|
||||
mappings.open = "<leader>gl";
|
||||
};
|
||||
};
|
||||
visuals = {
|
||||
rainbow-delimiters.enable = true;
|
||||
nvim-scrollbar = {
|
||||
enable = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue