# This workflow will build a Java project with Gradle # For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle name: Java CI with Gradle on: push: branches: [ xxx ] pull_request: branches: [ xxx ] jobs: build: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 - uses: gradle/wrapper-validation-action@v1 - name: Set up JDK 1.8 uses: actions/setup-java@v1 with: java-version: 1.8 - name: Build with Gradle run: gradle wrapper --gradle-version=4.6 --distribution-type=all
yet build fails due to gradle scripts incompability with newest gradle:
Run gradle wrapper --gradle-version=4.6 --distribution-type=all Welcome to Gradle 6.5.1! Here are the highlights of this release: - Experimental file-system watching - Improved version ordering - New samples For more details see https://docs.gradle.org/6.5.1/release-notes.html Starting a Gradle Daemon (subsequent builds will be faster) Configuration on demand is an incubating feature. FAILURE: Build failed with an exception. Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0. Use '--warning-mode all' to show the individual deprecation warnings. * Where: See https://docs.gradle.org/6.5.1/userguide/command_line_interface.html#sec:command_line_warnings Build file '/home/runner/work/xxx/xxx/xxx/build.gradle' line: 18 * What went wrong: A problem occurred evaluating project ':desktop'. > Could not get unknown property 'classesDir' for main classes of type org.gradle.api.internal.tasks.DefaultSourceSetOutput.
I am new to whole gradle thing, so perhaps I am doing something wrong?