diff --git a/nix/shell.nix b/nix/shell.nix index 74e8853d..b0b34f37 100644 --- a/nix/shell.nix +++ b/nix/shell.nix @@ -332,6 +332,10 @@ mkShell { make -C c_src fi + # Pre-compile test dependencies so mix test works immediately. + # The _build/test tree is ephemeral (cleared when nix devShell changes). + MIX_ENV=test mix deps.compile 2>/dev/null || true + # Auto-start services on first shell entry. # Run in a detached subshell to prevent nix develop from waiting # on daemonized PostgreSQL/Redis child processes.