nixpkgs/pkgs/tools/package-management/nixui/node-default.nix

25 lines
790 B
Nix
Raw Normal View History

2015-01-23 15:55:09 +01:00
{ nixui ? { outPath = ./.; name = "nixui"; }
, pkgs ? import <nixpkgs> {}
}:
let
2015-01-23 17:28:04 +01:00
nodePackages = import ../../../top-level/node-packages.nix {
2015-01-23 15:55:09 +01:00
inherit pkgs;
inherit (pkgs) stdenv nodejs fetchurl fetchgit;
neededNatives = [ pkgs.python ] ++ pkgs.lib.optional pkgs.stdenv.isLinux pkgs.utillinux;
self = nodePackages;
generated = ./node.nix;
};
in rec {
2015-01-23 17:28:04 +01:00
tarball = pkgs.runCommand "nixui.tgz" { buildInputs = [ pkgs.nodejs ]; } ''
2015-01-23 15:55:09 +01:00
mv `HOME=$PWD npm pack ${nixui}` $out
'';
build = nodePackages.buildNodePackage {
2015-01-23 17:28:04 +01:00
name = "nixui";
2015-01-23 15:55:09 +01:00
src = [ tarball ];
buildInputs = nodePackages.nativeDeps."nixui" or [];
2015-11-17 11:37:39 +01:00
deps = [ nodePackages.underscore nodePackages.nedb nodePackages.isnumber ];
2015-01-23 15:55:09 +01:00
peerDependencies = [];
passthru.names = [ "nixui" ];
};
2015-01-23 17:28:04 +01:00
}