Skip to content

Commit bcda408

Browse files
committed
plugins/treesitter: revert add iconsPackage
1 parent 2704133 commit bcda408

File tree

2 files changed

+4
-17
lines changed

2 files changed

+4
-17
lines changed

plugins/languages/treesitter/treesitter.nix

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -324,11 +324,6 @@ helpers.neovim-plugin.mkNeovimPlugin config {
324324
description = "Grammar packages to install";
325325
};
326326

327-
iconsPackage = helpers.mkPackageOption {
328-
name = "nvim-web-devicons";
329-
default = pkgs.vimPlugins.nvim-web-devicons;
330-
};
331-
332327
# TODO: Implement rawLua support to be passed into extraConfigLua.
333328
languageRegister = mkOption {
334329
type = with types; attrsOf (coercedTo str toList (listOf str));
@@ -416,11 +411,10 @@ helpers.neovim-plugin.mkNeovimPlugin config {
416411

417412
extraFiles = mkIf cfg.nixvimInjections { "queries/nix/injections.scm".source = ./injections.scm; };
418413

419-
extraPlugins =
420-
lib.optional (cfg.iconsPackage != null) cfg.iconsPackage
421-
++ lib.optional (cfg.package != null) (
422-
if cfg.nixGrammars then cfg.package.withPlugins (_: cfg.grammarPackages) else cfg.package
423-
);
414+
extraPlugins = mkIf (cfg.package != null) [
415+
(mkIf cfg.nixGrammars (cfg.package.withPlugins (_: cfg.grammarPackages)))
416+
(mkIf (!cfg.nixGrammars) cfg.package)
417+
];
424418

425419
extraPackages = [
426420
cfg.gccPackage

tests/test-sources/plugins/languages/treesitter/treesitter.nix

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -134,11 +134,4 @@
134134
};
135135
};
136136
};
137-
138-
no-icons = {
139-
plugins.treesitter = {
140-
enable = true;
141-
iconsPackage = null;
142-
};
143-
};
144137
}

0 commit comments

Comments
 (0)