nix-community.nixvim/flake-modules/lib.nix

35 lines
682 B
Nix
Raw Normal View History

{
self,
config,
lib,
withSystem,
...
2024-05-05 19:39:35 +02:00
}:
{
# Expose lib as a flake-parts module arg
_module.args = {
helpers = self.lib.nixvim;
};
# Public `lib` flake output
flake.lib =
{
nixvim = lib.makeOverridable (import ../lib) {
inherit lib;
flake = self;
};
}
// lib.genAttrs config.systems (
lib.flip withSystem (
{ pkgs, ... }:
{
# NOTE: this is the publicly documented flake output we've had for a while
check = pkgs.callPackage ../lib/tests.nix { inherit self; };
# NOTE: no longer needs to be per-system
helpers = self.lib.nixvim;
}
)
);
}