From 52836c04908eee521ccf1406775eb4708cd1c020 Mon Sep 17 00:00:00 2001 From: imbytecat Date: Sat, 11 Apr 2026 00:03:21 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20install.sh=20=E8=B7=AF=E5=BE=84=E6=94=B9?= =?UTF-8?q?=E4=B8=BA=20~/Developer=EF=BC=8C=E9=A6=96=E6=AC=A1=20bootstrap?= =?UTF-8?q?=20=E8=87=AA=E5=8A=A8=E6=A3=80=E6=B5=8B=20darwin-rebuild?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .sisyphus/ralph-loop.local.md | 10 ++++------ scripts/install.sh | 9 +++++++-- 2 files changed, 11 insertions(+), 8 deletions(-) diff --git a/.sisyphus/ralph-loop.local.md b/.sisyphus/ralph-loop.local.md index 84c7e5d..c893ec6 100644 --- a/.sisyphus/ralph-loop.local.md +++ b/.sisyphus/ralph-loop.local.md @@ -1,15 +1,13 @@ --- active: true -iteration: 2 +iteration: 3 max_iterations: 500 -completion_promise: "VERIFIED" +completion_promise: "DONE" initial_completion_promise: "DONE" -verification_attempt_id: "8bd02d34-4ca9-4686-b3ad-ae8a2330ad40" -started_at: "2026-04-10T15:43:59.279Z" +started_at: "2026-04-10T15:59:34.105Z" session_id: "ses_28863d32affeOW6Iiz2415uZSk" ultrawork: true -verification_pending: true strategy: "continue" -message_count_at_start: 169 +message_count_at_start: 191 --- Complete the task as instructed diff --git a/scripts/install.sh b/scripts/install.sh index 777bda6..52fa0ae 100755 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -2,18 +2,23 @@ set -euo pipefail REPO_URL="https://git.furtherverse.com/imbytecat/nix-config.git" -CONFIG_DIR="$HOME/.config/nix-config" +CONFIG_DIR="$HOME/Developer/nix-config" if [[ -d "$CONFIG_DIR/.git" ]]; then git -C "$CONFIG_DIR" pull else + mkdir -p "$HOME/Developer" git clone "$REPO_URL" "$CONFIG_DIR" fi case "$(uname)" in Darwin) TARGET="${1:?Usage: $0 }" - darwin-rebuild switch --flake "$CONFIG_DIR#$TARGET" + if command -v darwin-rebuild &>/dev/null; then + sudo darwin-rebuild switch --flake "$CONFIG_DIR#$TARGET" + else + sudo nix run nix-darwin -- switch --flake "$CONFIG_DIR#$TARGET" + fi ;; Linux) sudo nixos-rebuild switch --flake "$CONFIG_DIR#wsl"