From 278e1bfb893a6d978d990c28678ebf06b87508c4 Mon Sep 17 00:00:00 2001 From: seth Date: Sun, 18 Aug 2024 22:56:21 -0400 Subject: [PATCH] yarnConfigHook: apply as a postConfigure hook This follows in this example of npmConfigHook and allows for using this hook alongside others that may override configurePhase --- pkgs/build-support/node/fetch-yarn-deps/yarn-config-hook.sh | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pkgs/build-support/node/fetch-yarn-deps/yarn-config-hook.sh b/pkgs/build-support/node/fetch-yarn-deps/yarn-config-hook.sh index d11229aafc71c..7d8c70d270082 100644 --- a/pkgs/build-support/node/fetch-yarn-deps/yarn-config-hook.sh +++ b/pkgs/build-support/node/fetch-yarn-deps/yarn-config-hook.sh @@ -1,5 +1,4 @@ yarnConfigHook(){ - runHook preConfigure echo "Executing yarnConfigHook" # Use a constant HOME directory @@ -29,9 +28,8 @@ yarnConfigHook(){ patchShebangs node_modules echo "finished yarnConfigHook" - runHook postConfigure } -if [[ -z "${dontYarnInstallDeps-}" && -z "${configurePhase-}" ]]; then - configurePhase=yarnConfigHook +if [[ -z "${dontYarnInstallDeps-}" ]]; then + postConfigureHooks+=(yarnConfigHook) fi