From 0db223f456c122839f022927f95cc1e60cbbd25a Mon Sep 17 00:00:00 2001 From: Michael Bien Date: Sat, 6 Apr 2024 04:01:08 +0200 Subject: [PATCH] CI: hack to shorten windows paths - win has a 32k char process arg limit - test classpath args for the junit JVM can go over this limit if the workspace path is too long and the process will fail to start - this moves the workspace close to the drive letter as workaround --- .github/workflows/main.yml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 6ff6af193118..f33aab68a24a 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -2417,8 +2417,20 @@ jobs: exclude: - os: ${{ (contains(github.event.pull_request.labels.*.name, 'PHP') || contains(github.event.pull_request.labels.*.name, 'ci:all-tests') || github.event_name != 'pull_request') && 'nothing' || 'windows-latest' }} fail-fast: false + defaults: + run: + # hack: shorten paths to stay below 32k char process arg limit of windows + # note 'a' is apparently a mount point, we shouldn't go below that + # actions don't seem to care about the workspace attribute -> we symlink just for tests + working-directory: ${{ contains(matrix.os, 'windows') && 'D:\\a\\ws' || github.workspace }} + steps: + - name: symlink short paths for windows + if: contains(matrix.os, 'windows') + run: ln -s $(pwd) D:\\a\\ws + working-directory: ${{ github.workspace }} + - name: Set up JDK ${{ matrix.java }} uses: actions/setup-java@v4 with: