diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e432364994..6880d1d385 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -21,6 +21,7 @@ jobs: - 13 - 14 - 15 + - 16 steps: - uses: actions/checkout@v2.3.4 diff --git a/build.gradle b/build.gradle index a4b5739ed9..0fd88f31bb 100644 --- a/build.gradle +++ b/build.gradle @@ -38,9 +38,10 @@ buildscript { dependencies { classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:${versions.kotlin}" - classpath 'net.ltgt.gradle:gradle-errorprone-plugin:0.8.1' + classpath 'org.jetbrains.dokka:dokka-gradle-plugin:1.4.32' + classpath 'net.ltgt.gradle:gradle-errorprone-plugin:2.0.1' classpath 'com.android.tools.build:gradle:4.2.1' - classpath 'com.vanniktech:gradle-maven-publish-plugin:0.9.0' + classpath 'com.vanniktech:gradle-maven-publish-plugin:0.14.0' classpath 'com.google.protobuf:protobuf-gradle-plugin:0.8.12' classpath 'ru.vyarus:gradle-animalsniffer-plugin:1.5.0' classpath 'gradle.plugin.com.github.sherter.google-java-format:google-java-format-gradle-plugin:0.9' @@ -66,11 +67,20 @@ subprojects { task.targetCompatibility = JavaVersion.VERSION_1_8 } + tasks.withType(Test).configureEach { + testLogging { + if (System.getenv("CI") == "true") { + events = ["failed", "skipped", "passed"] + } + exceptionFormat "full" + } + } + apply plugin: 'net.ltgt.errorprone' dependencies { errorproneJavac 'com.google.errorprone:javac:9+181-r4173-1' - errorprone 'com.google.errorprone:error_prone_core:2.4.0' + errorprone 'com.google.errorprone:error_prone_core:2.7.1' } tasks.withType(JavaCompile).configureEach { task -> @@ -103,11 +113,11 @@ subprojects { } } - // google-java-format only works on JDK 11 or newer. - if (Jvm.current().javaVersion.isJava11Compatible()) { + // google-java-format only works on JDK 11 to JDK 15 (without wild flags). + if (Jvm.current().javaVersion.isJava11Compatible() && !Jvm.current().javaVersion.isCompatibleWith(JavaVersion.VERSION_16)) { project.apply plugin: 'com.github.sherter.google-java-format' googleJavaFormat { - toolVersion = '1.8' + toolVersion = '1.10.0' // By default, the GJF plugin includes all Java folders inside the project directory. This // does not work well with nested projects, especially when you want to exclude them. diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 549d84424d..69a9715077 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-6.9-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.1-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists