-
Notifications
You must be signed in to change notification settings - Fork 0
/
flake.nix
31 lines (29 loc) · 953 Bytes
/
flake.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
{
description = "Collection of functions and modules for nix in my own way";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
# TODO
# nix-parsec.url = "github:nprindle/nix-parsec";
};
outputs = { self, nixpkgs, ... } @ inputs: let
# TODO eachSystem
inherit (nixpkgs) lib;
fmway = import ./. { inherit lib; };
overlay = self: super: { inherit fmway; };
finalLib = lib.extend overlay;
in {
inherit fmway;
homeManagerModules.default = self.homeManagerModules.fmway;
homeManagerModules.fmway = {
imports = fmway.genTreeImports ./modules/homeManager;
nixpkgs.overlays = [ (_: _: { lib = finalLib; }) ];
};
nixosModules.default = self.nixosModules.fmway;
nixosModules.fmway = {
imports = fmway.genImportsWithDefault ./modules/nixos;
nixpkgs.overlays = [ (_: _: { lib = finalLib; }) ];
};
lib = finalLib;
overlays.default = overlay;
};
}