Skip to content

Commit e1deb37

Browse files
committed
fix: preserve v2 binary before rm -rf target in step 3
v2 lives under target/ — save it to /tmp before clearing.
1 parent f487838 commit e1deb37

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

.github/workflows/ci-macos.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -318,9 +318,11 @@ jobs:
318318
- name: Self-host again (v2 builds itself)
319319
run: |
320320
# Step 3: The self-hosted mcpp builds itself again (stability proof)
321+
# Save v2 before clearing target/
322+
cp "$MCPP_V2" /tmp/mcpp_v2
321323
rm -rf target
322-
MCPP_DIR=$(dirname "$MCPP_V2")
323-
export PATH="$MCPP_DIR:$PATH"
324+
export PATH="/tmp:$PATH"
325+
mv /tmp/mcpp_v2 /tmp/mcpp
324326
which mcpp
325327
mcpp build
326328
MCPP_V3=$(find target -path "*/bin/mcpp" | head -1)

0 commit comments

Comments
 (0)