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:
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user