From c276060cb1e0fbc15f272fdea1149c483e07929e Mon Sep 17 00:00:00 2001 From: phact Date: Wed, 26 Nov 2025 03:53:43 -0500 Subject: [PATCH] fix cleanup --- .github/workflows/test-integration.yml | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/.github/workflows/test-integration.yml b/.github/workflows/test-integration.yml index 28641819..2614699c 100644 --- a/.github/workflows/test-integration.yml +++ b/.github/workflows/test-integration.yml @@ -34,14 +34,23 @@ jobs: - name: Clean runner workspace run: | - # Clean old job workspaces - rm -rf ${GITHUB_WORKSPACE}/../../../_work/* || true - # Clean runner logs - rm -rf ${GITHUB_WORKSPACE}/../../../_diag/* || true + # Save current workspace path + CURRENT_WORKSPACE="${GITHUB_WORKSPACE}" + # Clean old job workspaces except current one + find ${GITHUB_WORKSPACE}/../../../_work -maxdepth 2 -type d -mtime +1 -not -path "${CURRENT_WORKSPACE}*" -exec rm -rf {} + 2>/dev/null || true + # Clean runner logs older than 1 day + find ${GITHUB_WORKSPACE}/../../../_diag -type f -mtime +1 -delete 2>/dev/null || true - run: df -h + - name: Checkout uses: actions/checkout@v4 + + - name: Verify workspace + run: | + echo "Current directory: $(pwd)" + echo "Workspace: ${GITHUB_WORKSPACE}" + ls -la - name: Set up UV uses: astral-sh/setup-uv@v3