nixpkgs/pkgs/top-level/node-packages.nix
Shea Levy 9817bada91 Update nodePackages to npm2nix-5.2.0
Signed-off-by: Shea Levy <shea@shealevy.com>
2013-11-05 18:02:21 -05:00

27 lines
816 B
Nix

{ pkgs, stdenv, nodejs, fetchurl, neededNatives, self, generated ? ./node-packages-generated.nix }:
{
nativeDeps = {
"node-expat" = [ pkgs.expat ];
"rbytes" = [ pkgs.openssl ];
"phantomjs" = [ pkgs.phantomjs ];
};
buildNodePackage = import ../development/web/nodejs/build-node-package.nix {
inherit stdenv nodejs neededNatives;
inherit (pkgs) runCommand;
};
patchLatest = srcAttrs:
let src = fetchurl srcAttrs; in pkgs.runCommand src.name {} ''
mkdir unpack
cd unpack
tar xf ${src}
mv */ package 2>/dev/null || true
sed -i -e "s/: \"latest\"/: \"*\"/" package/package.json
tar cf $out *
'';
/* Put manual packages below here (ideally eventually managed by npm2nix */
} // import generated { inherit self fetchurl; inherit (pkgs) lib; }