From f8533b6481c7cb9a39153bdcad333fb402417caa Mon Sep 17 00:00:00 2001 From: Natalie Date: Thu, 16 Apr 2026 18:11:20 -0700 Subject: [PATCH] =?UTF-8?q?fix(@projects/magic-civilization):=20?= =?UTF-8?q?=F0=9F=90=9B=20update=20build=20paths=20to=20use=20.local/build?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Lilith Autocommit --- scripts/run/remote.sh | 6 +++--- src/simulator/.cargo/config.toml | 5 +++++ src/simulator/build-gdext.sh | 6 +++--- 3 files changed, 11 insertions(+), 6 deletions(-) diff --git a/scripts/run/remote.sh b/scripts/run/remote.sh index 121ee2ec..89d69749 100644 --- a/scripts/run/remote.sh +++ b/scripts/run/remote.sh @@ -33,7 +33,7 @@ cmd_install_osx() { echo -e "${RED}Export failed.${NC}"; return 1 fi - BUILD_ZIP="$REPO_ROOT/builds/$VERSION/macos/$ZIP_NAME" + BUILD_ZIP="$REPO_ROOT/.local/build/godot/$VERSION/macos/$ZIP_NAME" [ -f "$BUILD_ZIP" ] || { echo -e "${RED}Build artifact not found: $BUILD_ZIP${NC}"; return 1; } echo -e "${GREEN} ✓ Exported $(du -h "$BUILD_ZIP" | cut -f1)${NC}" @@ -116,7 +116,7 @@ cmd_install_ios() { echo -e "${YELLOW}[1/4] Exporting iOS Xcode project...${NC}" "$REPO_ROOT/tools/export-single.sh" ios "$VERSION" $EXPORT_FLAG 2>&1 || { echo -e "${RED}Export failed.${NC}"; return 1; } - local BUILD_DIR="$REPO_ROOT/builds/$VERSION/ios" + local BUILD_DIR="$REPO_ROOT/.local/build/godot/$VERSION/ios" [ -d "$BUILD_DIR/MagicCivilization.xcodeproj" ] || { echo -e "${RED}Xcode project not found${NC}"; return 1; } echo -e "${GREEN} ✓ Xcode project exported${NC}" @@ -172,7 +172,7 @@ cmd_install_android() { echo "" "$REPO_ROOT/tools/export-single.sh" android "$VERSION" $EXPORT_FLAG 2>&1 || { echo -e "${RED}Export failed.${NC}"; return 1; } - local APK="$REPO_ROOT/builds/$VERSION/android/MagicCivilization.apk" + local APK="$REPO_ROOT/.local/build/godot/$VERSION/android/MagicCivilization.apk" [ -f "$APK" ] || { echo -e "${RED}APK not found: $APK${NC}"; return 1; } echo -e "${GREEN} ✓ Exported $(du -h "$APK" | cut -f1)${NC}" diff --git a/src/simulator/.cargo/config.toml b/src/simulator/.cargo/config.toml index 39ae6505..87cc4e45 100644 --- a/src/simulator/.cargo/config.toml +++ b/src/simulator/.cargo/config.toml @@ -1,3 +1,8 @@ +[build] +# Build artifacts live outside src/ in the repo's .local/ tree (gitignored). +# Prevents 25GB of cargo target/ from polluting src/simulator/. +target-dir = "../../.local/build/rust" + [env] # Rayon thread pool overhead exceeds benefit for small test fixtures (1x1, 2x2 grids). # This sets RAYON_NUM_THREADS=1 for all cargo commands in this workspace, making rayon diff --git a/src/simulator/build-gdext.sh b/src/simulator/build-gdext.sh index 9ac386ee..a0c7febe 100755 --- a/src/simulator/build-gdext.sh +++ b/src/simulator/build-gdext.sh @@ -12,19 +12,19 @@ mkdir -p "$ADDON_DIR" case "$TARGET" in x86_64-unknown-linux-gnu) rm -f "$ADDON_DIR/libmagic_civ_physics.x86_64.so" - cp "$SCRIPT_DIR/target/$TARGET/release/libmagic_civ_physics_gdext.so" \ + cp "$SCRIPT_DIR/../../.local/build/rust/$TARGET/release/libmagic_civ_physics_gdext.so" \ "$ADDON_DIR/libmagic_civ_physics.x86_64.so" echo "Copied → engine/addons/magic_civ_physics/libmagic_civ_physics.x86_64.so" ;; x86_64-pc-windows-gnu|x86_64-pc-windows-msvc) rm -f "$ADDON_DIR/magic_civ_physics.x86_64.dll" - cp "$SCRIPT_DIR/target/$TARGET/release/magic_civ_physics_gdext.dll" \ + cp "$SCRIPT_DIR/../../.local/build/rust/$TARGET/release/magic_civ_physics_gdext.dll" \ "$ADDON_DIR/magic_civ_physics.x86_64.dll" echo "Copied → engine/addons/magic_civ_physics/magic_civ_physics.x86_64.dll" ;; aarch64-apple-darwin|x86_64-apple-darwin) rm -f "$ADDON_DIR/libmagic_civ_physics.dylib" - cp "$SCRIPT_DIR/target/$TARGET/release/libmagic_civ_physics_gdext.dylib" \ + cp "$SCRIPT_DIR/../../.local/build/rust/$TARGET/release/libmagic_civ_physics_gdext.dylib" \ "$ADDON_DIR/libmagic_civ_physics.dylib" echo "Copied → engine/addons/magic_civ_physics/libmagic_civ_physics.dylib" ;;