fix: probe Nix store with supported command\n\nUse nix store ping instead of the nonexistent nix-store --ping operation.\n\nPosted-by: ChatGPT (GPT-5.6 Sol)

This commit is contained in:
Ed Langley
2026-09-26 00:56:25 -07:00
parent c6c8c1fb7f
commit ad1032d35f
+2 -2
View File
@@ -43,7 +43,7 @@ ensure_nix_daemon() {
# Single-user Nix does not need a daemon; multi-user/cloud installs do.
# If the store already answers, leave the environment alone.
if command -v nix-store >/dev/null 2>&1 && nix-store --ping >/dev/null 2>&1; then
if nix --extra-experimental-features 'nix-command' store ping >/dev/null 2>&1; then
return 0
fi
@@ -58,7 +58,7 @@ ensure_nix_daemon() {
# The daemon is started asynchronously; wait briefly for its socket before
# invoking the seed/build steps that depend on it.
for _ in {1..50}; do
if command -v nix-store >/dev/null 2>&1 && nix-store --ping >/dev/null 2>&1; then
if nix --extra-experimental-features 'nix-command' store ping --store daemon >/dev/null 2>&1; then
return 0
fi
sleep 0.1