dragnpkgs/flake.nix

51 lines
1.4 KiB
Nix
Raw Normal View History

{
description = "dragnpkgs together with nixpkgs and lix";
inputs = {
2024-10-21 21:31:19 +00:00
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
lix-module = {
url = "https://git.lix.systems/lix-project/nixos-module/archive/2.91.0.tar.gz";
flake = false;
};
lix = {
url = "https://git.lix.systems/lix-project/lix/archive/2.91.0.tar.gz";
flake = false;
};
};
outputs = { self, nixpkgs, lix, lix-module }:
let
overlays = [
(import ./overlay.nix)
(import "${lix-module}/overlay.nix" { inherit lix; })
];
forAllSystems = nixpkgs.lib.genAttrs nixpkgs.lib.systems.flakeExposed;
in {
lib = nixpkgs.lib.extend (final: prev: {
2024-10-21 21:37:02 +00:00
nixosSystem = args:
import "${nixpkgs}/nixos/lib/eval-config.nix" (
{
lib = final;
system = null;
modules = args.modules ++ [
({ config, pkgs, lib, ... }: {
config.nixpkgs.flake.source = self.outPath;
2024-10-21 21:44:09 +00:00
config.nixpkgs.overlays = overlays;
2024-10-21 21:37:02 +00:00
})
2024-10-21 21:56:47 +00:00
(import ./module.nix)
2024-10-21 21:37:02 +00:00
];
} // builtins.removeAttrs args [ "modules" ]
);
});
legacyPackages = forAllSystems (system:
nixpkgs.legacyPackages.${system}.appendOverlays overlays
);
nixosModules = nixpkgs.nixosModules;
};
}