mirror of
https://github.com/NotAShelf/nvf.git
synced 2025-11-09 23:15:30 +00:00
feat: refactor and separate LSP/language configurations
This commit is contained in:
parent
7a71f06763
commit
6b512f132a
30 changed files with 1266 additions and 522 deletions
27
modules/languages/default.nix
Normal file
27
modules/languages/default.nix
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
{lib, ...}:
|
||||
with lib; let
|
||||
mkEnable = desc:
|
||||
mkOption {
|
||||
description = "Turn on ${desc} for enabled langauges by default";
|
||||
type = types.bool;
|
||||
default = false;
|
||||
};
|
||||
in {
|
||||
imports = [
|
||||
./clang.nix
|
||||
./go.nix
|
||||
./nix.nix
|
||||
./python.nix
|
||||
./rust.nix
|
||||
./sql.nix
|
||||
./ts.nix
|
||||
./zig.nix
|
||||
];
|
||||
|
||||
options.vim.languages = {
|
||||
enableLSP = mkEnable "LSP";
|
||||
enableTreesitter = mkEnable "treesitter";
|
||||
enableFormat = mkEnable "formatting";
|
||||
enableExtraDiagnostics = mkEnable "extra diagnostics";
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue