forked from svanderburg/node2nix
-
Notifications
You must be signed in to change notification settings - Fork 1
/
flake.nix
28 lines (26 loc) · 896 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
{
description = "Generate Nix expressions to build NPM packages";
inputs.nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
inputs.flake-utils.url = "github:numtide/flake-utils";
outputs = { self, nixpkgs, flake-utils }:
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = nixpkgs.legacyPackages.${system};
inherit (import ./default.nix { inherit pkgs; })
sources package shell nodeDependencies;
node2nix = package;
app = flake-utils.lib.mkApp {
drv = package;
exePath = "/bin/node2nix";
};
overlays = final: prev: { node2nix = node2nix; };
in {
packages.node2nix = node2nix;
packages.default = node2nix;
apps.node2nix = app;
apps.default = app;
nodeDependencies = nodeDependencies;
nodeShell = shell;
inherit overlays;
});
}