node-packages: update & cleanup

* update packages for v4
* remove files and generation for v0_10 and v5 as nodejs-5_x and nodejs-0_10 are no longer supported
This commit is contained in:
Christine Koppelt 2016-10-29 23:08:01 +02:00
parent ac75b9b263
commit 182b1c2777
7 changed files with 2934 additions and 29655 deletions

View File

@ -1,16 +0,0 @@
# This file has been generated by node2nix 1.1.0. Do not edit!
{pkgs ? import <nixpkgs> {
inherit system;
}, system ? builtins.currentSystem, nodejs ? pkgs."nodejs-5_x"}:
let
nodeEnv = import ./node-env.nix {
inherit (pkgs) stdenv python utillinux runCommand writeTextFile;
inherit nodejs;
};
in
import ./node-packages-v5.nix {
inherit (pkgs) fetchurl fetchgit;
inherit nodeEnv;
}

View File

@ -1,33 +0,0 @@
{pkgs, system, nodejs}:
let
nodePackages = import ./composition-v4.nix {
inherit pkgs system nodejs;
};
in
nodePackages // {
node-inspector = nodePackages.node-inspector.override (oldAttrs: {
buildInputs = oldAttrs.buildInputs ++ [ nodePackages.node-pre-gyp ];
});
phantomjs = nodePackages.phantomjs.override (oldAttrs: {
buildInputs = oldAttrs.buildInputs ++ [ pkgs.phantomjs ];
});
webdrvr = nodePackages.webdrvr.override (oldAttrs: {
buildInputs = oldAttrs.buildInputs ++ [ pkgs.phantomjs ];
preRebuild = ''
mkdir $TMPDIR/webdrvr
ln -s ${pkgs.fetchurl {
url = "https://selenium-release.storage.googleapis.com/2.43/selenium-server-standalone-2.43.1.jar";
sha1 = "ef1b5f8ae9c99332f99ba8794988a1d5b974d27b";
}} $TMPDIR/webdrvr/selenium-server-standalone-2.43.1.jar
ln -s ${pkgs.fetchurl {
url = "http://chromedriver.storage.googleapis.com/2.10/chromedriver_linux64.zip";
sha1 = "26220f7e43ee3c0d714860db61c4d0ecc9bb3d89";
}} $TMPDIR/webdrvr/chromedriver_linux64.zip
'';
});
}

View File

@ -1,44 +0,0 @@
{pkgs, system, nodejs}:
let
nodePackages = import ./composition-v5.nix {
inherit pkgs system nodejs;
};
in
nodePackages // {
node-inspector = nodePackages.node-inspector.override (oldAttrs: {
buildInputs = oldAttrs.buildInputs ++ [ nodePackages.node-pre-gyp ];
});
phantomjs = nodePackages.phantomjs.override (oldAttrs: {
buildInputs = oldAttrs.buildInputs ++ [ pkgs.phantomjs2 ];
});
webdrvr = nodePackages.webdrvr.override (oldAttrs: {
buildInputs = oldAttrs.buildInputs ++ [ pkgs.phantomjs ];
preRebuild = ''
mkdir $TMPDIR/webdrvr
ln -s ${pkgs.fetchurl {
url = "https://selenium-release.storage.googleapis.com/2.43/selenium-server-standalone-2.43.1.jar";
sha1 = "ef1b5f8ae9c99332f99ba8794988a1d5b974d27b";
}} $TMPDIR/webdrvr/selenium-server-standalone-2.43.1.jar
ln -s ${pkgs.fetchurl {
url = "http://chromedriver.storage.googleapis.com/2.10/chromedriver_linux64.zip";
sha1 = "26220f7e43ee3c0d714860db61c4d0ecc9bb3d89";
}} $TMPDIR/webdrvr/chromedriver_linux64.zip
'';
dontNpmInstall = true; # We face an error with underscore not found, but the package will work fine if we ignore this.
});
bower2nix = nodePackages.bower2nix.override (oldAttrs: {
buildInputs = oldAttrs.buildInputs ++ [ pkgs.makeWrapper ];
postInstall = ''
for prog in bower2nix fetch-bower; do
wrapProgram "$out/bin/$prog" --prefix PATH : "${pkgs.git}/bin"
done
'';
});
}

View File

@ -2,4 +2,3 @@
rm -f node-env.nix
node2nix -i node-packages.json -o node-packages-v4.nix -c composition-v4.nix
node2nix -5 -i node-packages.json -o node-packages-v5.nix -c composition-v5.nix

View File

@ -121,7 +121,7 @@ let
if [ -f "${src}" ]
then
# Figure out what directory has been unpacked
packageDir="$(find . -type d -maxdepth 1 | tail -1)"
packageDir=$(find . -type d -maxdepth 1 | tail -1)
# Restore write permissions to make building work
find "$packageDir" -type d -print0 | xargs -0 chmod u+x
@ -131,8 +131,6 @@ let
mv "$packageDir" "$DIR/${packageName}"
elif [ -d "${src}" ]
then
strippedName="$(stripHash ${src})"
# Restore write permissions to make building work
chmod -R u+w $strippedName
@ -140,6 +138,9 @@ let
mv $strippedName "$DIR/${packageName}"
fi
# Unset the stripped name to not confuse the next unpack step
unset strippedName
# Some version specifiers (latest, unstable, URLs, file paths) force NPM to make remote connections or consult paths outside the Nix store.
# The following JavaScript replaces these by * to prevent that
cd "$DIR/${packageName}"

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff