mirror of
https://github.com/nix-community/nixvim.git
synced 2025-07-15 03:34:31 +02:00
modules: refactor module bootstrapping
Let's simplify things by defining all modules in `./plugins`, `./modules` and `./wrappers/modules`. Instead of currying `pkgs` into a bootstrapping module, we can require `defaultPkgs` be provided as a special arg. This refactor allows us to completely remove `flake-modules/modules.nix`!
This commit is contained in:
parent
3d96960348
commit
d2afb176ff
16 changed files with 129 additions and 159 deletions
13
modules/misc/default.nix
Normal file
13
modules/misc/default.nix
Normal file
|
@ -0,0 +1,13 @@
|
|||
{ defaultPkgs, ... }:
|
||||
let
|
||||
# We can't use config._module.args to define imports,
|
||||
# so we're forced to use specialArgs.defaultPkgs's path
|
||||
nixosModules = defaultPkgs.path + "/nixos/modules/";
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
./nixpkgs.nix
|
||||
./nixvim-info.nix
|
||||
(nixosModules + "/misc/meta.nix")
|
||||
];
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue