-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathflake.nix
29 lines (28 loc) · 900 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
{
inputs = {
nixpkgs.url = "nixpkgs";
nixpkgs-unstable.url = "github:nixos/nixpkgs/master";
flake-utils.url = "github:numtide/flake-utils";
};
outputs = { self, nixpkgs, nixpkgs-unstable, flake-utils }:
let
localOverlay = import ./nix/overlay.nix;
overlayUnstable = final: prev: {
# allow the ability to add an unstable package as required.
unstable = nixpkgs-unstable.legacyPackages.${prev.system};
};
overlays = [ overlayUnstable localOverlay ];
in flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs {
inherit system overlays;
};
in {
legacyPackages = pkgs;
inherit (pkgs) devShell;
}) // {
# platform independent attrs
overlay = final: prev: (nixpkgs.lib.composeManyExtensions overlays) final prev;
inherit overlays;
};
}