refactor: clean up nvf

This commit is contained in:
Mohammad Rafiq 2025-03-16 20:48:17 +08:00
parent 09c2fc94a4
commit 1446b84212
28 changed files with 98 additions and 691 deletions

View file

@ -1,23 +1,8 @@
{
programs.nvf.settings.vim = {
projects.project-nvim.enable = true;
utility = {
# ccc is a colour picker
ccc.enable = true;
# diffview-nvim lets you easily go through diffs for a given rev
diffview-nvim.enable = true;
# direnv.vim syncs the nvim shell environment with direnv
direnv.enable = true;
# icon-picker gives you a way to pick icons from nerd fonts
# TODO: find out keybinds
icon-picker.enable = true;
# image rendering
# TODO: look into image-magick and if it is needed
images.image-nvim = {
enable = true;
setupOpts.backend = "kitty";
};
# leetcode
nix-develop.enable = true;
leetcode-nvim = {
enable = true;
setupOpts = {
@ -25,68 +10,13 @@
lang = "rust";
};
};
# mkdir.nvim creates directory when the path doesnt exist
mkdir.enable = true;
motion = {
hop.enable = true; # <leader>h
leap.enable = true;
leap.mappings = {
# default mappings
# - Leap backward till:<leader>sX
# - Leap backward to:<leader>sS
# - Leap forward till:<leader>sx
# - Leap forward to:<leader>ss
# - Leap from window:gs
};
# precognition.nvim shows hints for motions
precognition = {
enable = false;
setupOpts = {
# TODO: may want to fix dashboard
};
};
};
# multicursors.nvim enables vscode like multicursors
multicursors.enable = true;
# new-file-template.nvim automatically inserts templates in new files
new-file-template = {
enable = true;
# add a directory containing lua/tempaltes/*.lua to vim.additionalRuntimePaths
# TODO: add for nix
};
# allows usage of nix commands in nvim
nix-develop.enable = true;
# aerial.nvim shows a preview of your entire code file
outline.aerial-nvim.enable = true; # "g0"
# glow.nvim displays a floating window with a markdown preview
preview.glow.enable = true; # "<leader>p"
# nvim-surround allows you to easily surround and delete words or phrases
surround.enable = true;
# vim-wakatime allows sending statistics to wakatime or a compatible backend vim-wakatime.enable = true;
# yanky allows cycling through yank history when putting text
yanky-nvim.enable = true;
# yazi-nvim gives integration with yazi
# default mappings:
# - Open yazi at the current file [yazi.nvim]:<leader>-
# - Open the file manager in nvims working directory [yazi.nvim]:<leader>cw
# - Resume the last yazi session [yazi.nvim]:<c-up>
yazi-nvim.enable = true;
yazi-nvim.setupOpts.open_for_directories = true; # FIXME: does this work with neotree?
};
# TODO: look into terminal integration
terminal.toggleterm.enable = true;
terminal.toggleterm.lazygit.enable = true;
# nvim session manager manages sessions like folders in vscode
session.nvim-session-manager = {
enable = true;
mappings = {
# default mappings:
# - Delete session:<leader>sd
# - Load last session:<leader>slt
# - Load session:<leader>sl
# - Save current session:<leader>sc
};
};
comments.comment-nvim.enable = true;
session.nvim-session-manager.enable = true;
};
}