mirror of
https://github.com/nix-community/nixvim.git
synced 2025-11-21 17:59:41 +01:00
lib/evalNixvim: deprecate specialArgs.helpers
This has been soft-deprecated for several releases. Now that we have removed our internal usage, we can introduce an eval warning.
This commit is contained in:
parent
dad19c1238
commit
82bc02466c
3 changed files with 9 additions and 2 deletions
|
|
@ -48,8 +48,12 @@ in
|
|||
# however see https://github.com/nix-community/nixvim/issues/2879
|
||||
inherit lib;
|
||||
modulesPath = ../modules;
|
||||
# TODO: deprecate `helpers`
|
||||
helpers = self;
|
||||
# TODO: deprecated 2025-11-19
|
||||
helpers = lib.warn ''
|
||||
nixvim: the `helpers` module arg has been renamed to `lib.nixvim`.
|
||||
Nixvim modules can access this via the `lib` module arg.
|
||||
For wrapper modules (e.g. NixOS or Home Manager modules), see:
|
||||
https://nix-community.github.io/nixvim/lib/nixvim/index.html#accessing-nixvims-functions'' self;
|
||||
}
|
||||
// extraSpecialArgs;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -20,6 +20,7 @@ let
|
|||
message = "Expected lib.nixvim.enableExceptInTests to be true";
|
||||
}
|
||||
{
|
||||
# NOTE: evaluating `helpers` here prints an eval warning
|
||||
assertion = !helpers.enableExceptInTests;
|
||||
message = "Expected helpers.enableExceptInTests to be false";
|
||||
}
|
||||
|
|
@ -40,6 +41,7 @@ let
|
|||
message = "Expected lib.nixvim.enableExceptInTests to be true";
|
||||
}
|
||||
{
|
||||
# NOTE: evaluating `helpers` here prints an eval warning
|
||||
assertion = helpers.enableExceptInTests;
|
||||
message = "Expected helpers.enableExceptInTests to be true";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ let
|
|||
message = "lib.nixvim should be defined";
|
||||
}
|
||||
{
|
||||
# NOTE: evaluating `helpers` here prints an eval warning
|
||||
assertion = builtins.attrNames lib.nixvim == builtins.attrNames helpers;
|
||||
message = "lib.nixvim and helpers should be aliases";
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue