From 3b962bd4cbe8b5c339b29a8b5c6fbaaf2eb2d694 Mon Sep 17 00:00:00 2001 From: Siavash Sameni Date: Wed, 8 Apr 2026 22:13:26 +0400 Subject: [PATCH] fix: build scripts use git reset --hard before pull to recover from dirty state Cargo.lock changes from Docker builds caused pull conflicts. Now uses reset --hard + clean -fd to guarantee clean state before pulling. Co-Authored-By: Claude Opus 4.6 (1M context) --- scripts/build-and-notify.sh | 3 ++- scripts/build-linux-docker.sh | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/scripts/build-and-notify.sh b/scripts/build-and-notify.sh index 0f990d7..f3b0002 100755 --- a/scripts/build-and-notify.sh +++ b/scripts/build-and-notify.sh @@ -51,7 +51,8 @@ trap 'notify "WZP Android build FAILED! Check /tmp/wzp-build.log"' ERR if [ "$DO_PULL" = "1" ]; then echo ">>> Pulling latest..." cd "$BASE_DIR/data/source" - git checkout -- . 2>/dev/null || true + git reset --hard HEAD 2>/dev/null || true + git clean -fd 2>/dev/null || true git pull origin feat/android-voip-client 2>&1 | tail -3 fi diff --git a/scripts/build-linux-docker.sh b/scripts/build-linux-docker.sh index d2fc9ad..2bea90c 100755 --- a/scripts/build-linux-docker.sh +++ b/scripts/build-linux-docker.sh @@ -52,7 +52,8 @@ trap 'notify "WZP Linux build FAILED! Check /tmp/wzp-linux-build.log"' ERR if [ "$DO_PULL" = "1" ]; then echo ">>> Pulling latest..." cd "$BASE_DIR/data/source" - git checkout -- . 2>/dev/null || true + git reset --hard HEAD 2>/dev/null || true + git clean -fd 2>/dev/null || true git pull origin feat/android-voip-client 2>&1 | tail -3 fi