diff --git a/pkgs/development/web/nodejs/build-node-package.nix b/pkgs/development/web/nodejs/build-node-package.nix index d260b2900160..8a56e3e798b9 100644 --- a/pkgs/development/web/nodejs/build-node-package.nix +++ b/pkgs/development/web/nodejs/build-node-package.nix @@ -38,6 +38,7 @@ stdenv.mkDerivation ({ mkdir -p $out/node_modules mv node_modules/${requireName} $out/node_modules mv node_modules/.bin $out/node_modules 2>/dev/null || true + rm -fR $out/node_modules/${requireName}/node_modules mv node_modules $out/node_modules/${requireName} if [ -d "$out/node_modules/.bin" ]; then ln -sv node_modules/.bin $out/bin