From 307a6817d433386ea1bfb86e8964ac0a0a05b78c Mon Sep 17 00:00:00 2001 From: yueh Date: Tue, 28 Jul 2020 14:49:33 +0200 Subject: [PATCH] Remove xvfb steps as runData should now run headless (#4513) Also run `prepareRunData` in a separate step to avoid a race condition with ForgeGradle writing the generated dependency after it has already written it for `runData` --- .github/workflows/branches.yml | 7 ++++--- .github/workflows/master.yml | 7 ++++--- .github/workflows/pull_requests.yml | 7 ++++--- .github/workflows/release.yml | 7 ++++--- 4 files changed, 16 insertions(+), 12 deletions(-) diff --git a/.github/workflows/branches.yml b/.github/workflows/branches.yml index 4ac445b70..ff68a5613 100644 --- a/.github/workflows/branches.yml +++ b/.github/workflows/branches.yml @@ -25,10 +25,11 @@ jobs: run: ./gradlew clean --no-daemon - name: Validate no assets run: test ! -d ./src/generated + # FG does appear to read the deps in runData before it has written it. Separate step to avoid it + - name: Compile Java and prepare runData + run: ./gradlew compileJava prepareRunData --no-daemon - name: Generate assets - uses: GabrielBB/xvfb-action@v1.2 - with: - run: ./gradlew runData --no-daemon + run: ./gradlew runData --no-daemon - name: Validate assets run: test -d ./src/generated -a -f ./src/generated/resources/.cache/cache - name: Build with Gradle diff --git a/.github/workflows/master.yml b/.github/workflows/master.yml index d55923846..ded3bb27c 100644 --- a/.github/workflows/master.yml +++ b/.github/workflows/master.yml @@ -25,10 +25,11 @@ jobs: run: ./gradlew clean --no-daemon - name: Validate no assets run: test ! -d ./src/generated + # FG does appear to read the deps in runData before it has written it. Separate step to avoid it + - name: Compile Java and prepare runData + run: ./gradlew compileJava prepareRunData --no-daemon - name: Generate assets - uses: GabrielBB/xvfb-action@v1.2 - with: - run: ./gradlew runData --no-daemon + run: ./gradlew runData --no-daemon - name: Validate assets run: test -d ./src/generated -a -f ./src/generated/resources/.cache/cache - name: Build with Gradle diff --git a/.github/workflows/pull_requests.yml b/.github/workflows/pull_requests.yml index 397ea6c5d..934aa6d30 100644 --- a/.github/workflows/pull_requests.yml +++ b/.github/workflows/pull_requests.yml @@ -25,10 +25,11 @@ jobs: run: ./gradlew clean --no-daemon - name: Validate no assets run: test ! -d ./src/generated + # FG does appear to read the deps in runData before it has written it. Separate step to avoid it + - name: Compile Java and prepare runData + run: ./gradlew compileJava prepareRunData --no-daemon - name: Generate assets - uses: GabrielBB/xvfb-action@v1.2 - with: - run: ./gradlew runData --no-daemon + run: ./gradlew runData --no-daemon - name: Validate assets run: test -d ./src/generated -a -f ./src/generated/resources/.cache/cache - name: Build with Gradle diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index b450879f2..80e56c720 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -30,10 +30,11 @@ jobs: run: chmod +x gradlew - name: Validate no assets run: test ! -d ./src/generated + # FG does appear to read the deps in runData before it has written it. Separate step to avoid it + - name: Compile Java and prepare runData + run: ./gradlew compileJava prepareRunData --no-daemon - name: Generate assets - uses: GabrielBB/xvfb-action@v1.2 - with: - run: ./gradlew runData --no-daemon + run: ./gradlew runData --no-daemon - name: Validate assets run: test -d ./src/generated -a -f ./src/generated/resources/.cache/cache - name: Build with Gradle