From e5dc78430182712fa6963f286495f6c3271c8074 Mon Sep 17 00:00:00 2001 From: maulanasdqn Date: Wed, 21 Jan 2026 18:14:52 +0700 Subject: [PATCH] fix(nix): handle Nx terminal crash for Vite apps MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add fallback check to continue if build output exists even when Nx crashes after successful build completion. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 --- nix/mkViteApp.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/nix/mkViteApp.nix b/nix/mkViteApp.nix index 8d826fd..d00622b 100644 --- a/nix/mkViteApp.nix +++ b/nix/mkViteApp.nix @@ -27,7 +27,8 @@ pkgs.buildNpmPackage { export NX_TASKS_RUNNER_DYNAMIC_OUTPUT=false export NX_NATIVE=false ${pkgs.lib.concatStringsSep "\n" (pkgs.lib.mapAttrsToList (k: v: "export ${k}=\"${v}\"") envVars)} - ./node_modules/.bin/nx build ${name} --output-style=static + # Run nx build, ignore terminal crash after successful build + ./node_modules/.bin/nx build ${name} --output-style=static || test -d dist/apps/${name} runHook postBuild '';