lib/languages: re-add toVimBool

This commit is contained in:
raf 2024-12-03 00:52:08 +03:00
parent 0650aa31ac
commit 5a5f49f85f
Signed by: NotAShelf
GPG key ID: AF26552424E53993

View file

@ -6,7 +6,12 @@
inherit (lib.nvim.attrsets) mapListToAttrs;
in {
# Converts a boolean to a yes/no string. This is used in lots of
# configuration formats.
# configuration formats, and is not covered by `toLuaObject`
toVimBool = bool:
if bool
then "yes"
else "no";
diagnosticsToLua = {
lang,
config,
@ -30,8 +35,8 @@ in {
mkEnable = desc:
mkOption {
description = "Turn on ${desc} for enabled languages by default";
type = bool;
default = false;
type = bool;
description = "Turn on ${desc} for enabled languages by default";
};
}