Revert "helpers: add mkPackageOption + refactoring (#144)" (#149)

This reverts commit b724085447.
This commit is contained in:
Pedro Alves 2023-01-25 00:03:26 +00:00 committed by GitHub
parent b724085447
commit 2d54272177
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
58 changed files with 258 additions and 94 deletions

View file

@ -1,6 +1,6 @@
{ lib, pkgs, ... }@attrs:
let
helpers = import ../../helpers.nix { inherit lib; };
helpers = import ../../helpers.nix { lib = lib; };
in with helpers; with lib;
{
mkCmpSourcePlugin = { name, extraPlugins ? [], useDefaultPackage ? true, ... }: mkPlugin attrs {

View file

@ -2,7 +2,7 @@
with lib;
let
cfg = config.plugins.nvim-cmp;
helpers = import ../../helpers.nix { inherit lib; };
helpers = import ../../helpers.nix { lib = lib; };
mkNullOrOption = helpers.mkNullOrOption;
cmpLib = import ./cmp-helpers.nix args;
# functionName should be a string
@ -17,7 +17,11 @@ in
options.plugins.nvim-cmp = {
enable = mkEnableOption "nvim-cmp";
package = helpers.mkPackageOption "nvim-cmp" pkgs.vimPlugins.nvim-cmp;
package = mkOption {
type = types.package;
default = pkgs.vimPlugins.nvim-cmp;
description = "Plugin to use for nvim-cmp";
};
performance = mkOption {
default = null;