mirror of
https://github.com/nix-community/nixvim.git
synced 2025-06-24 09:48:42 +02:00
helpers: move rawType to helpers.nixvimTypes (#871)
This is done in preparation of adding new (lua) types to help the documentation.
This commit is contained in:
parent
2f13e3a21d
commit
af41ea2d80
38 changed files with 80 additions and 75 deletions
|
@ -14,7 +14,7 @@ with lib; let
|
|||
with types;
|
||||
oneOf [
|
||||
str
|
||||
helpers.rawType
|
||||
helpers.nixvimTypes.rawLua
|
||||
(listOf str)
|
||||
(attrsOf (either str ints.unsigned))
|
||||
]
|
||||
|
@ -593,7 +593,7 @@ in {
|
|||
|
||||
path =
|
||||
helpers.defaultNullOpts.mkNullable
|
||||
(with types; either str helpers.rawType)
|
||||
(with types; either str helpers.nixvimTypes.rawLua)
|
||||
''{__raw = "string.format('%s/fidget.nvim.log', vim.fn.stdpath('cache'))";}''
|
||||
''
|
||||
Where Fidget writes its logs to.
|
||||
|
|
|
@ -323,7 +323,7 @@ with lib; let
|
|||
nullOr
|
||||
(
|
||||
listOf
|
||||
(either str helpers.rawType)
|
||||
(either str helpers.nixvimTypes.rawLua)
|
||||
);
|
||||
description = ''
|
||||
An array of abosolute or workspace-relative paths that will be added to the workspace
|
||||
|
|
|
@ -190,7 +190,7 @@ in {
|
|||
miscFormatters = languageTools "misc" "formatters";
|
||||
|
||||
mkChooseOption = lang: kind: possible: let
|
||||
toolType = with types; either (enum possible) helpers.rawType;
|
||||
toolType = with types; either (enum possible) helpers.nixvimTypes.rawLua;
|
||||
in
|
||||
mkOption {
|
||||
type = with types; either toolType (listOf toolType);
|
||||
|
|
|
@ -357,7 +357,7 @@ in {
|
|||
overrides =
|
||||
helpers.defaultNullOpts.mkNullable
|
||||
(types.listOf
|
||||
(types.oneOf [types.bool types.str helpers.rawType]))
|
||||
(types.oneOf [types.bool types.str helpers.nixvimTypes.rawLua]))
|
||||
"[true]"
|
||||
''
|
||||
Specifies a list of alternate or supplemental command-line options.
|
||||
|
|
|
@ -51,7 +51,7 @@ in {
|
|||
Default AI popup type.
|
||||
'';
|
||||
|
||||
openaiApiKey = helpers.mkNullOrOption (with types; either str helpers.rawType) ''
|
||||
openaiApiKey = helpers.mkNullOrOption (with types; either str helpers.nixvimTypes.rawLua) ''
|
||||
An alternative way to set your API key.
|
||||
'';
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue