mirror of
https://github.com/nix-community/nixvim.git
synced 2025-08-15 07:02:58 +02:00
plugins/nonels: remove with lib and helpers
This commit is contained in:
parent
fb677540e1
commit
33d030d23c
3 changed files with 19 additions and 23 deletions
|
@ -4,7 +4,6 @@ sourceType: sourceName:
|
|||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
helpers,
|
||||
...
|
||||
}:
|
||||
let
|
||||
|
@ -20,7 +19,7 @@ in
|
|||
{
|
||||
enable = lib.mkEnableOption "the ${sourceName} ${sourceType} source for none-ls";
|
||||
# Support strLua for compatibility with the old withArgs option
|
||||
settings = helpers.defaultNullOpts.mkStrLuaOr' {
|
||||
settings = lib.nixvim.defaultNullOpts.mkStrLuaOr' {
|
||||
type = with lib.types; attrsOf anything;
|
||||
description = ''
|
||||
Options provided to the `require('null-ls').builtins.${sourceType}.${sourceName}.with` function.
|
||||
|
@ -82,7 +81,7 @@ in
|
|||
plugins.none-ls.settings.sources = lib.mkDefault [
|
||||
(
|
||||
"require('null-ls').builtins.${sourceType}.${sourceName}"
|
||||
+ lib.optionalString (cfg'.settings != null) ".with(${helpers.toLuaObject cfg'.settings})"
|
||||
+ lib.optionalString (cfg'.settings != null) ".with(${lib.nixvim.toLuaObject cfg'.settings})"
|
||||
)
|
||||
];
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue