Unverified Commit 964e93cb authored by Austin Horstman's avatar Austin Horstman
Browse files

eslint: fix darwin

parent 9ea293f7
Loading
Loading
Loading
Loading
+4740 −1481

File changed.

Preview size limit exceeded, changes collapsed.

+14 −3
Original line number Diff line number Diff line
@@ -2,9 +2,15 @@
  lib,
  buildNpmPackage,
  fetchFromGitHub,
  stdenv,
  overrideSDK,
}:

buildNpmPackage rec {
let
  buildNpmPackage' = buildNpmPackage.override {
    stdenv = if stdenv.isDarwin then overrideSDK stdenv "11.0" else stdenv;
  };
in
buildNpmPackage' rec {
  pname = "eslint";
  version = "9.9.1";

@@ -15,11 +21,16 @@ buildNpmPackage rec {
    hash = "sha256-n07a50bigglwr3ItZqbyQxu0mPZawTSVunwIe8goJBQ=";
  };

  # NOTE: Generating lock-file
  # arch = [ x64 arm64 ]
  # platform = [ darwin linux]
  # npm install --package-lock-only --arch=<arch> --platform=<os>
  # darwin seems to generate a cross platform compatible lockfile
  postPatch = ''
    cp ${./package-lock.json} package-lock.json
  '';

  npmDepsHash = "sha256-/E1JUsbPyHzWJ4kuNRg/blYRaAdATYbk+jnJFJyzHLE=";
  npmDepsHash = "sha256-sqQ7YeCMMK/9/XOX6QHZjX+2U+dYHkKiAzsLI0ehpAE=";

  dontNpmBuild = true;
  dontNpmPrune = true;