nvf/extra.nix

212 lines
4.7 KiB
Nix
Raw Normal View History

2023-02-07 12:03:21 +00:00
inputs: let
2023-02-10 17:39:31 +00:00
modulesWithInputs = import ./modules inputs;
2023-02-07 12:03:21 +00:00
neovimConfiguration = {
modules ? [],
pkgs,
lib ? pkgs.lib,
check ? true,
extraSpecialArgs ? {},
}:
modulesWithInputs {
inherit pkgs lib check extraSpecialArgs;
2023-02-10 17:39:31 +00:00
configuration.imports = modules;
2023-02-07 12:03:21 +00:00
};
tidalConfig = {
config.vim.languages.tidal.enable = true;
};
2023-02-07 12:03:21 +00:00
mainConfig = isMaximal: {
config = {
vim = {
viAlias = true;
vimAlias = true;
2023-03-01 08:34:23 +00:00
debugMode = {
2023-03-01 09:45:42 +00:00
enable = false;
2023-03-01 08:34:23 +00:00
level = 20;
logFile = "/tmp/nvim.log";
};
2023-02-07 12:03:21 +00:00
};
2023-04-17 22:48:44 +00:00
vim.lsp = {
formatOnSave = true;
lspkind.enable = false;
lightbulb.enable = true;
lspsaga.enable = false;
nvimCodeActionMenu.enable = true;
trouble.enable = true;
lspSignature.enable = true;
};
vim.languages = {
enableLSP = true;
enableFormat = true;
enableTreesitter = true;
enableExtraDiagnostics = true;
nix.enable = true;
2023-04-17 22:05:18 +00:00
html.enable = isMaximal;
2023-02-07 12:03:21 +00:00
clang.enable = isMaximal;
sql.enable = isMaximal;
rust = {
enable = isMaximal;
crates.enable = true;
2023-02-07 12:03:21 +00:00
};
ts.enable = isMaximal;
go.enable = isMaximal;
zig.enable = isMaximal;
python.enable = isMaximal;
dart.enable = isMaximal;
elixir.enable = isMaximal;
2023-02-07 12:03:21 +00:00
};
vim.visuals = {
enable = true;
nvimWebDevicons.enable = true;
scrollBar.enable = true;
smoothScroll.enable = true;
cellularAutomaton.enable = true;
fidget-nvim.enable = true;
2023-02-07 12:03:21 +00:00
indentBlankline = {
enable = true;
fillChar = null;
eolChar = null;
2023-02-07 12:03:21 +00:00
showCurrContext = true;
};
cursorWordline = {
enable = true;
lineTimeout = 0;
};
};
2023-03-01 08:34:23 +00:00
vim.statusline = {
lualine = {
2023-03-01 09:45:42 +00:00
enable = true;
2023-03-01 08:34:23 +00:00
theme = "catppuccin";
};
2023-02-07 12:03:21 +00:00
};
vim.theme = {
enable = true;
name = "catppuccin";
style = "mocha";
};
vim.autopairs.enable = true;
vim.autocomplete = {
enable = true;
2023-02-07 12:03:21 +00:00
type = "nvim-cmp";
};
vim.filetree = {
nvimTreeLua = {
enable = true;
renderer = {
rootFolderLabel = null;
};
2023-02-07 12:03:21 +00:00
view = {
width = 25;
};
};
};
vim.tabline = {
nvimBufferline.enable = true;
};
vim.treesitter.context.enable = true;
2023-02-07 12:03:21 +00:00
vim.binds = {
whichKey.enable = true;
cheatsheet.enable = true;
};
vim.telescope.enable = true;
2023-02-07 12:03:21 +00:00
vim.git = {
enable = true;
gitsigns.enable = true;
2023-04-17 21:55:27 +00:00
gitsigns.codeActions = true;
2023-02-07 12:03:21 +00:00
};
vim.minimap = {
minimap-vim.enable = false;
codewindow.enable = true; # lighter, faster, and uses lua for configuration
};
vim.dashboard = {
dashboard-nvim.enable = false;
alpha.enable = true;
};
vim.notify = {
nvim-notify.enable = true;
};
2023-04-07 17:36:27 +00:00
vim.projects = {
project-nvim.enable = true;
};
2023-02-07 12:03:21 +00:00
vim.utility = {
colorizer.enable = true;
icon-picker.enable = true;
venn-nvim.enable = false; # FIXME throws an error when its commands are ran manually
2023-03-01 09:08:24 +00:00
diffview-nvim.enable = true;
2023-04-04 23:14:13 +00:00
motion = {
hop.enable = true;
leap.enable = true;
};
2023-02-07 12:03:21 +00:00
};
vim.notes = {
obsidian.enable = false; # FIXME neovim fails to build if obsidian is enabled
orgmode.enable = false;
mind-nvim.enable = true;
todo-comments.enable = true;
2023-02-07 12:03:21 +00:00
};
vim.terminal = {
toggleterm.enable = true;
};
vim.ui = {
noice.enable = true;
2023-04-05 13:59:08 +00:00
smartcolumn.enable = true;
2023-02-07 12:03:21 +00:00
};
vim.assistant = {
copilot.enable = isMaximal;
#tabnine.enable = false; # FIXME: this is not working because the plugin depends on an internal script to be ran by the package manager
2023-02-07 12:03:21 +00:00
};
vim.session = {
nvim-session-manager.enable = true;
2023-02-07 12:03:21 +00:00
};
vim.gestures = {
gesture-nvim.enable = false;
};
vim.comments = {
comment-nvim.enable = true;
};
vim.presence = {
presence-nvim = {
enable = true;
auto_update = true;
image_text = "The Superior Text Editor";
client_id = "793271441293967371";
main_image = "neovim";
rich_presence = {
editing_text = "Editing %s";
};
};
};
2023-02-07 12:03:21 +00:00
};
};
in {
inherit neovimConfiguration mainConfig tidalConfig;
2023-02-07 12:03:21 +00:00
}