Commit 4df54803 authored by Felix Buehler's avatar Felix Buehler
Browse files

element-desktop: migrate to prefetch-yarn-deps

parent 3832b75e
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -3,7 +3,7 @@
, fetchFromGitHub
, makeWrapper
, makeDesktopItem
, fixup_yarn_lock
, prefetch-yarn-deps
, yarn
, nodejs
, fetchYarnDeps
@@ -41,7 +41,7 @@ stdenv.mkDerivation (finalAttrs: builtins.removeAttrs pinData [ "hashes" ] // {
    sha256 = desktopYarnHash;
  };

  nativeBuildInputs = [ yarn fixup_yarn_lock nodejs makeWrapper jq ]
  nativeBuildInputs = [ yarn prefetch-yarn-deps nodejs makeWrapper jq ]
    ++ lib.optionals stdenv.isDarwin [ desktopToDarwinBundle ];

  inherit seshat;
@@ -51,7 +51,7 @@ stdenv.mkDerivation (finalAttrs: builtins.removeAttrs pinData [ "hashes" ] // {

    export HOME=$(mktemp -d)
    yarn config --offline set yarn-offline-mirror $offlineCache
    fixup_yarn_lock yarn.lock
    fixup-yarn-lock yarn.lock
    yarn install --offline --frozen-lockfile --ignore-platform --ignore-scripts --no-progress --non-interactive
    patchShebangs node_modules/

+3 −3
Original line number Diff line number Diff line
{ lib, stdenv, rustPlatform, fetchFromGitHub, callPackage, sqlcipher, nodejs, python3, yarn, fixup_yarn_lock, CoreServices, fetchYarnDeps, removeReferencesTo }:
{ lib, stdenv, rustPlatform, fetchFromGitHub, callPackage, sqlcipher, nodejs, python3, yarn, prefetch-yarn-deps, CoreServices, fetchYarnDeps, removeReferencesTo }:

let
  pinData = lib.importJSON ./pin.json;
@@ -16,7 +16,7 @@ in rustPlatform.buildRustPackage rec {

  sourceRoot = "${src.name}/seshat-node/native";

  nativeBuildInputs = [ nodejs python3 yarn ];
  nativeBuildInputs = [ nodejs python3 yarn prefetch-yarn-deps ];
  buildInputs = [ sqlcipher ] ++ lib.optional stdenv.isDarwin CoreServices;

  npm_config_nodedir = nodejs;
@@ -33,7 +33,7 @@ in rustPlatform.buildRustPackage rec {
    export HOME=$PWD/tmp
    mkdir -p $HOME
    yarn config --offline set yarn-offline-mirror $yarnOfflineCache
    ${fixup_yarn_lock}/bin/fixup_yarn_lock yarn.lock
    fixup-yarn-lock yarn.lock
    yarn install --offline --frozen-lockfile --ignore-platform --ignore-scripts --no-progress --non-interactive
    patchShebangs node_modules/
    node_modules/.bin/neon build --release