Merge pull request #141682 from hercules-ci/fix-netlify

Fix `netlify-cli` build
This commit is contained in:
Robert Hensing 2021-10-15 19:46:22 +02:00 committed by GitHub
commit bcd05cd2ab
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 27 additions and 14 deletions

View file

@ -1,6 +1,7 @@
{ pkgs, nodejs, stdenv, applyPatches, fetchFromGitHub, fetchpatch, fetchurl }:
let
inherit (pkgs) lib;
since = (version: pkgs.lib.versionAtLeast nodejs.version version);
before = (version: pkgs.lib.versionOlder nodejs.version version);
super = import ./composition.nix {
@ -319,23 +320,11 @@ let
};
netlify-cli =
let
esbuild = pkgs.esbuild.overrideAttrs (old: rec {
version = "0.13.6";
src = fetchFromGitHub {
owner = "netlify";
repo = "esbuild";
rev = "v${version}";
sha256 = "0asjmqfzdrpfx2hd5hkac1swp52qknyqavsm59j8xr4c1ixhc6n9";
};
});
in
super.netlify-cli.override {
preRebuild = ''
export ESBUILD_BINARY_PATH="${esbuild}/bin/esbuild"
export ESBUILD_BINARY_PATH="${pkgs.esbuild_netlify}/bin/esbuild"
'';
meta.maintainers = with lib.maintainers; [ roberth ];
};
ssb-server = super.ssb-server.override {

View file

@ -0,0 +1,22 @@
{ buildGoModule, fetchFromGitHub, lib }:
buildGoModule rec {
pname = "esbuild";
version = "0.13.6";
src = fetchFromGitHub {
owner = "netlify";
repo = "esbuild";
rev = "v${version}";
sha256 = "0asjmqfzdrpfx2hd5hkac1swp52qknyqavsm59j8xr4c1ixhc6n9";
};
vendorSha256 = "sha256-2ABWPqhK2Cf4ipQH7XvRrd+ZscJhYPc3SV2cGT0apdg=";
meta = with lib; {
description = "A fork of esbuild maintained by netlify";
homepage = "https://github.com/netlify/esbuild";
license = licenses.mit;
maintainers = with maintainers; [ roberth ];
};
}

View file

@ -1614,6 +1614,8 @@ with pkgs;
esbuild = callPackage ../development/tools/esbuild { };
esbuild_netlify = callPackage ../development/tools/esbuild/netlify.nix { };
essentia-extractor = callPackage ../tools/audio/essentia-extractor { };
esh = callPackage ../tools/text/esh { };