mirror of
https://github.com/nix-community/nixvim.git
synced 2025-07-02 05:14:30 +02:00
plugins: remove redundant mkRaw
apply
functions
`strLua` now does this coercion internally.
This commit is contained in:
parent
bd6aa476b8
commit
2cda50d530
15 changed files with 0 additions and 26 deletions
|
@ -125,7 +125,6 @@ lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
|||
|
||||
See `:help conform.format` for details.
|
||||
'';
|
||||
apply = v: if lib.isString v then mkRaw v else v;
|
||||
};
|
||||
|
||||
default_format_opts = defaultNullOpts.mkNullable defaultFormatSubmodule { } ''
|
||||
|
@ -143,7 +142,6 @@ lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
|||
|
||||
See `:help conform.format` for details.
|
||||
'';
|
||||
apply = v: if lib.isString v then mkRaw v else v;
|
||||
};
|
||||
|
||||
log_level = defaultNullOpts.mkLogLevel "error" ''
|
||||
|
|
|
@ -151,7 +151,6 @@ helpers.neovim-plugin.mkNeovimPlugin {
|
|||
});
|
||||
default = null;
|
||||
example = "require('noice.util.spinners').spinners.circleFull";
|
||||
apply = v: if isString v then helpers.mkRaw v else v;
|
||||
description = "Spinner for pinned views that are loading.";
|
||||
pluginDefault = {
|
||||
frames = defaultFrames;
|
||||
|
@ -182,7 +181,6 @@ helpers.neovim-plugin.mkNeovimPlugin {
|
|||
# Hence, we convert the string to raw lua in `apply`.
|
||||
keys = helpers.defaultNullOpts.mkAttrsOf' {
|
||||
type = with lib.types; either strLuaFn (enum [ false ]);
|
||||
apply = x: if x == null then null else mapAttrs (_: v: if isString v then helpers.mkRaw v else v) x;
|
||||
description = ''
|
||||
Buffer-local keymaps to be added to edgebar buffers.
|
||||
Existing buffer-local keymaps will never be overridden.
|
||||
|
|
|
@ -156,7 +156,6 @@ with lib;
|
|||
end
|
||||
'';
|
||||
};
|
||||
apply = mapAttrs (_: helpers.mkRaw);
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
@ -91,7 +91,6 @@ let
|
|||
example = ''
|
||||
require('lint.parser').from_pattern(pattern, groups, severity_map, defaults, opts)
|
||||
'';
|
||||
apply = helpers.mkRaw;
|
||||
mandatory = true;
|
||||
};
|
||||
};
|
||||
|
|
|
@ -17,7 +17,6 @@ lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
|||
adapters = mkOption {
|
||||
type = with types; listOf strLua;
|
||||
default = [ ];
|
||||
apply = map mkRaw;
|
||||
# NOTE: We hide this option from the documentation as users should use the top-level
|
||||
# `adapters` option.
|
||||
# They can still directly append raw lua code to this `settings.adapters` option.
|
||||
|
|
|
@ -55,7 +55,6 @@ lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
|||
For "static" delimiter pairs it can be a list of strings representing the value
|
||||
of the delimiter pair.
|
||||
'';
|
||||
apply = v: if lib.isString v then lib.nixvim.mkRaw v else v;
|
||||
example = [
|
||||
"( "
|
||||
" )"
|
||||
|
|
|
@ -226,7 +226,6 @@ with lib;
|
|||
action = mkOption {
|
||||
type = lib.types.strLua;
|
||||
description = "The lua code for this keymap action.";
|
||||
apply = helpers.mkRaw;
|
||||
};
|
||||
opts = helpers.keymaps.mapConfigOptions // {
|
||||
buffer = helpers.defaultNullOpts.mkBool false ''
|
||||
|
|
|
@ -30,7 +30,6 @@ with lib;
|
|||
};
|
||||
})
|
||||
);
|
||||
apply = v: map (listElem: if isString listElem then helpers.mkRaw listElem else listElem) v;
|
||||
default = [ ];
|
||||
description = ''
|
||||
Startify displays lists. Each list consists of a `type` and optionally a `header` and
|
||||
|
|
|
@ -129,7 +129,6 @@ helpers.neovim-plugin.mkNeovimPlugin {
|
|||
description = ''
|
||||
Builtin click handlers.
|
||||
'';
|
||||
apply = mapAttrs (_: helpers.mkRaw);
|
||||
example = {
|
||||
Lnum = "require('statuscol.builtin').lnum_click";
|
||||
FoldClose = "require('statuscol.builtin').foldclose_click";
|
||||
|
|
|
@ -95,7 +95,6 @@ rec {
|
|||
${defaults}
|
||||
```
|
||||
'';
|
||||
apply = lib.mapAttrs (_: lib.nixvim.mkRaw);
|
||||
};
|
||||
|
||||
mkMappingsOption =
|
||||
|
|
|
@ -18,7 +18,6 @@ helpers.neovim-plugin.mkNeovimPlugin {
|
|||
|
||||
patterns = mkOption {
|
||||
type = with lib.types; listOf strLua;
|
||||
apply = map helpers.mkRaw;
|
||||
default = [ ];
|
||||
example = [ "[[%s/\(\n\n\)\n\+/\1/]]" ];
|
||||
description = ''
|
||||
|
|
|
@ -22,7 +22,6 @@ in
|
|||
onAttach = helpers.defaultNullOpts.mkLuaFn "__lspOnAttach" "Lua code to run when tsserver attaches to a buffer.";
|
||||
handlers = mkOption {
|
||||
type = with lib.types; nullOr (attrsOf strLuaFn);
|
||||
apply = v: helpers.ifNonNull' v (mapAttrs (_: helpers.mkRaw) v);
|
||||
default = null;
|
||||
description = "How tsserver should respond to LSP requests";
|
||||
example = {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue