Skip to content

Commit

Permalink
treesitter: add ignoreInstall option to treesitter config (#38)
Browse files Browse the repository at this point in the history
  • Loading branch information
ForsakenHarmony committed Sep 1, 2022
1 parent f9304b5 commit 88fb867
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions plugins/languages/treesitter.nix
Expand Up @@ -15,9 +15,15 @@ in
description = "Install grammars with Nix (beta)";
};
ensureInstalled = mkOption {
type = with types; oneOf [ (enum [ "all" "maintained" ]) (listOf str) ];
default = "maintained";
description = "Either \"all\", \"maintained\" or a list of languages";
type = with types; oneOf [ (enum ["all"]) (listOf str) ];
default = "all";
description = "Either \"all\" or a list of languages";
};

ignoreInstall = mkOption {
type = types.listOf types.str;
default = [];
description = "List of parsers to ignore installing (for \"all\")";
};

disabledLanguages = mkOption {
Expand Down Expand Up @@ -77,6 +83,7 @@ in
} else null;

ensure_installed = cfg.ensureInstalled;
ignore_install = cfg.ignoreInstall;
};
in mkIf cfg.enable {
programs.nixvim = {
Expand All @@ -96,3 +103,4 @@ in
};
};
}

0 comments on commit 88fb867

Please sign in to comment.