fix: run fixed, click action fixed

This commit is contained in:
Michael Freno
2026-01-08 12:23:19 -05:00
parent c417398116
commit 6c6e1679a9
14 changed files with 68 additions and 23 deletions

13
run
View File

@@ -77,7 +77,18 @@ elif [ "$ACTION" = "run" ]; then
if [ $? -eq 0 ]; then
echo "✅ Build succeeded!"
run_with_output "open -a \"Gaze\""
# Get the actual build output directory from xcodebuild
BUILD_DIR="$(xcodebuild -project Gaze.xcodeproj -scheme Gaze -configuration Debug -showBuildSettings 2>/dev/null | grep -m 1 "BUILT_PRODUCTS_DIR" | sed 's/.*= //')"
APP_PATH="${BUILD_DIR}/Gaze.app"
if [ -d "$APP_PATH" ]; then
echo "🚀 Launching: $APP_PATH"
open "$APP_PATH"
else
echo "⚠️ App not found at expected location, trying fallback..."
# Fallback to derived data location
open "$HOME/Library/Developer/Xcode/DerivedData/Gaze-*/Build/Products/Debug/Gaze.app"
fi
else
echo "❌ Build failed!"
exit 1