diff options
author | Mathijs Kwik <mathijs@bluescreen303.nl> | 2012-09-04 17:46:32 +0200 |
---|---|---|
committer | Mathijs Kwik <mathijs@bluescreen303.nl> | 2012-09-04 17:49:32 +0200 |
commit | 278312a38cdf0735957eefb8354627fd5191f9b4 (patch) | |
tree | 134f6dbc1382cd4d1c3d349f7b3e0cc4d60b93d8 | |
parent | df82c942635c045658ea618438d8b433f79348c9 (diff) |
node-packages: ability to fix sources that use the impure "latest" dependency
-rw-r--r-- | pkgs/top-level/node-packages.nix | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/pkgs/top-level/node-packages.nix b/pkgs/top-level/node-packages.nix index ae468d95eaced..ee05b92a255d6 100644 --- a/pkgs/top-level/node-packages.nix +++ b/pkgs/top-level/node-packages.nix @@ -5,6 +5,14 @@ let self = { inherit stdenv nodejs; }; + patchLatest = srcAttrs: + let src = fetchurl srcAttrs; in + pkgs.runCommand src.name {} '' + tar xf ${src} + sed -i -e "s/: \"latest\"/: \"*\"/" package/package.json + tar cf $out package + ''; + "abbrev" = self."abbrev-1"; "abbrev-1" = self.buildNodePackage rec { |