haste-server: 72863858338a57d54eb9dee55530e90ebbc22453 -> 68f6fe2b96ad02e21645480448113954bc87e1f5

This commit is contained in:
R. Ryantm 2022-05-10 04:48:26 +00:00
parent 5a68a4274d
commit 0684166637
4 changed files with 36 additions and 26 deletions

View File

@ -9,13 +9,13 @@
stdenv.mkDerivation rec {
pname = "haste-server";
version = "72863858338a57d54eb9dee55530e90ebbc22453";
version = "68f6fe2b96ad02e21645480448113954bc87e1f5";
src = fetchFromGitHub {
owner = "toptal";
repo = "haste-server";
rev = version;
hash = "sha256-MoEqpfihI3ZqSTHOxFbGziDv8khgq2Nd44YuKYDGflc=";
hash = "sha256-9IPGqIca6GC/dQhGBC4hxWhNRgXR1ik0ONRBU2MGhL0=";
};
nativeBuildInputs = [

View File

@ -1,4 +1,4 @@
# This file has been generated by node2nix 1.9.0. Do not edit!
# This file has been generated by node2nix 1.11.1. Do not edit!
{pkgs ? import <nixpkgs> {
inherit system;

View File

@ -1,4 +1,4 @@
# This file has been generated by node2nix 1.9.0. Do not edit!
# This file has been generated by node2nix 1.11.1. Do not edit!
{nodeEnv, fetchurl, fetchgit, nix-gitignore, stdenv, lib, globalBuildInputs ? []}:
@ -67,13 +67,13 @@ let
sha512 = "8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==";
};
};
"async-1.0.0" = {
"async-3.2.3" = {
name = "async";
packageName = "async";
version = "1.0.0";
version = "3.2.3";
src = fetchurl {
url = "https://registry.npmjs.org/async/-/async-1.0.0.tgz";
sha1 = "f8fc04ca3a13784ade9e1641af98578cfbd647a9";
url = "https://registry.npmjs.org/async/-/async-3.2.3.tgz";
sha512 = "spZRyzKL5l5BZQrr/6m/SqFdBN0q3OCI0f9rjfBzCMBIP4p75P620rR3gTmaksNOhmzgdxcaxdNfMy6anrbM0g==";
};
};
"async-cache-1.1.0" = {
@ -1237,13 +1237,13 @@ let
sha512 = "QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==";
};
};
"winston-2.4.5" = {
"winston-2.4.6" = {
name = "winston";
packageName = "winston";
version = "2.4.5";
version = "2.4.6";
src = fetchurl {
url = "https://registry.npmjs.org/winston/-/winston-2.4.5.tgz";
sha512 = "TWoamHt5yYvsMarGlGEQE59SbJHqGsZV8/lwC+iCcGeAe0vUaOh+Lv6SYM17ouzC/a/LB1/hz/7sxFBtlu1l4A==";
url = "https://registry.npmjs.org/winston/-/winston-2.4.6.tgz";
sha512 = "J5Zu4p0tojLde8mIOyDSsmLmcP8I3Z6wtwpTDHx1+hGcdhxcJaAmG4CFtagkb+NiN1M9Ek4b42pzMWqfc9jm8w==";
};
};
"workerpool-6.1.0" = {
@ -1341,7 +1341,7 @@ let
name = "haste";
packageName = "haste";
version = "0.1.0";
src = ../../../../../../../../../nix/store/jmii2np1kr78g0pnyf2y8wvj09nc1pr0-source;
src = ../../../../../../../../../nix/store/6mkl6xr6y74v0ib122gjx8jvd6xig4dc-source;
dependencies = [
sources."@ungap/promise-all-settled-1.1.2"
sources."ansi-colors-4.1.1"
@ -1349,7 +1349,7 @@ let
sources."ansi-styles-4.3.0"
sources."anymatch-3.1.2"
sources."argparse-2.0.1"
sources."async-1.0.0"
sources."async-3.2.3"
sources."async-cache-1.1.0"
sources."balanced-match-1.0.2"
sources."base64-js-1.5.1"
@ -1495,7 +1495,7 @@ let
sources."utils-merge-1.0.1"
sources."which-2.0.2"
sources."wide-align-1.1.3"
sources."winston-2.4.5"
sources."winston-2.4.6"
sources."workerpool-6.1.0"
(sources."wrap-ansi-7.0.0" // {
dependencies = [

View File

@ -98,7 +98,7 @@ let
''
+ (lib.concatMapStrings (dependency:
''
if [ ! -e "${dependency.name}" ]; then
if [ ! -e "${dependency.packageName}" ]; then
${composePackage dependency}
fi
''
@ -257,8 +257,8 @@ let
var packageLock = JSON.parse(fs.readFileSync("./package-lock.json"));
if(![1, 2].includes(packageLock.lockfileVersion)) {
process.stderr.write("Sorry, I only understand lock file versions 1 and 2!\n");
process.exit(1);
process.stderr.write("Sorry, I only understand lock file versions 1 and 2!\n");
process.exit(1);
}
if(packageLock.dependencies !== undefined) {
@ -390,7 +390,7 @@ let
buildNodePackage =
{ name
, packageName
, version
, version ? null
, dependencies ? []
, buildInputs ? []
, production ? true
@ -409,7 +409,7 @@ let
extraArgs = removeAttrs args [ "name" "dependencies" "buildInputs" "dontStrip" "dontNpmInstall" "preRebuild" "unpackPhase" "buildPhase" "meta" ];
in
stdenv.mkDerivation ({
name = "${name}-${version}";
name = "${name}${if version == null then "" else "-${version}"}";
buildInputs = [ tarWrapper python nodejs ]
++ lib.optional (stdenv.isLinux) utillinux
++ lib.optional (stdenv.isDarwin) libtool
@ -441,6 +441,14 @@ let
if [ -d "$out/lib/node_modules/.bin" ]
then
ln -s $out/lib/node_modules/.bin $out/bin
# Patch the shebang lines of all the executables
ls $out/bin/* | while read i
do
file="$(readlink -f "$i")"
chmod u+rwx "$file"
patchShebangs "$file"
done
fi
# Create symlinks to the deployed manual page folders, if applicable
@ -471,7 +479,7 @@ let
buildNodeDependencies =
{ name
, packageName
, version
, version ? null
, src
, dependencies ? []
, buildInputs ? []
@ -489,7 +497,7 @@ let
extraArgs = removeAttrs args [ "name" "dependencies" "buildInputs" ];
in
stdenv.mkDerivation ({
name = "node-dependencies-${name}-${version}";
name = "node-dependencies-${name}${if version == null then "" else "-${version}"}";
buildInputs = [ tarWrapper python nodejs ]
++ lib.optional (stdenv.isLinux) utillinux
@ -519,6 +527,7 @@ let
if [ -f ${src}/package-lock.json ]
then
cp ${src}/package-lock.json .
chmod 644 package-lock.json
fi
''}
@ -541,7 +550,7 @@ let
buildNodeShell =
{ name
, packageName
, version
, version ? null
, src
, dependencies ? []
, buildInputs ? []
@ -557,9 +566,10 @@ let
let
nodeDependencies = buildNodeDependencies args;
extraArgs = removeAttrs args [ "name" "dependencies" "buildInputs" "dontStrip" "dontNpmInstall" "unpackPhase" "buildPhase" ];
in
stdenv.mkDerivation {
name = "node-shell-${name}-${version}";
stdenv.mkDerivation ({
name = "node-shell-${name}${if version == null then "" else "-${version}"}";
buildInputs = [ python nodejs ] ++ lib.optional (stdenv.isLinux) utillinux ++ buildInputs;
buildCommand = ''
@ -578,7 +588,7 @@ let
export NODE_PATH=${nodeDependencies}/lib/node_modules
export PATH="${nodeDependencies}/bin:$PATH"
'';
};
} // extraArgs);
in
{
buildNodeSourceDist = lib.makeOverridable buildNodeSourceDist;