Skip to content

Commit b5e53d8

Browse files
authored
Updated Gradle and some dependencies including Kotlin (#1343)
* Updated Gradle (through new wrapper task) and some dependencies including Kotlin. Tweaked some gradle files to change where kapt plugin is applied to make it possible to use them with latest stable Kotlin version. * Reverted Gradle to 5.0 since further updates are blocked by kotlin-metadata's compiler using a conflicting version of Kotlin * Fixed unscoped calls to async coroutine builder * Updated some additional dependencies * Updated Gradle Versions Plugin which no longer reports by default if a custom outputFormatter is used so it needed additional setup to print the report. This may be improved later by hooking to the resolution strategy instead of the outputFormatter for what we are doing. * Used separate kotlin version definition for ank since it is not working properly with None / Some with latest Kotlin 1.3.21 but works on 1.3.11.
1 parent 383a1e7 commit b5e53d8

File tree

40 files changed

+101
-63
lines changed

40 files changed

+101
-63
lines changed

build.gradle

Lines changed: 24 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -14,24 +14,27 @@
1414
* limitations under the License.
1515
*/
1616

17+
import com.github.benmanes.gradle.versions.reporter.PlainTextReporter
18+
1719
buildscript {
1820
ext {
1921
// Constants
20-
gradleVersion = '4.10'
21-
gradleVersionsPluginVersion = '0.20.0'
22-
javaVersion = JavaVersion.VERSION_1_7
22+
ankKotlinVersion = '1.3.11'
23+
daggerVersion = '2.21'
24+
detekt_version = '1.0.0-RC12'
25+
dokka_version = '0.9.17'
26+
gradleVersionsPluginVersion = '0.21.0'
2327
jUnitVersion = '4.12'
24-
jUnitVintageVersion = '5.2.0'
28+
jUnitVintageVersion = '5.4.0'
29+
javaVersion = JavaVersion.VERSION_1_7
30+
kotlinPoetVersion = '1.1.0'
2531
kotlinTestVersion = '3.3.1'
26-
kotlinVersion = '1.3.11'
27-
daggerVersion = '2.17'
28-
kotlinxCoroutinesVersion = '1.1.0'
32+
kotlinVersion = '1.3.21'
2933
kotlinxCollectionsImmutableVersion = '0.1'
30-
kotlinPoetVersion = '1.1.0'
31-
projectReactorVersion = '3.1.8.RELEASE'
32-
rxJavaVersion = '2.2.1'
33-
dokka_version = '0.9.17'
34-
detekt_version = '1.0.0-RC12'
34+
kotlinxCoroutinesVersion = '1.1.1'
35+
projectReactorVersion = '3.2.6.RELEASE'
36+
retrofitVersion = '2.5.0'
37+
rxJavaVersion = '2.2.7'
3538
}
3639

3740
repositories {
@@ -49,7 +52,7 @@ buildscript {
4952
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion"
5053
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.4'
5154
classpath 'io.arrow-kt:ank-gradle-plugin:0.7.1'
52-
classpath 'org.ajoberstar:gradle-git-publish:1.0.1'
55+
classpath 'org.ajoberstar:gradle-git-publish:2.0.0'
5356
classpath "net.rdrei.android.buildtimetracker:gradle-plugin:0.11.1"
5457
classpath "org.jetbrains.dokka:dokka-gradle-plugin:$dokka_version"
5558
classpath "io.gitlab.arturbosch.detekt:detekt-gradle-plugin:$detekt_version"
@@ -212,6 +215,11 @@ tasks.create('repl') {
212215
}
213216
}
214217

218+
tasks.wrapper {
219+
gradleVersion = "5.0"
220+
distributionType = Wrapper.DistributionType.ALL
221+
}
222+
215223
apply plugin: 'com.github.ben-manes.versions'
216224

217225
configurations.all {
@@ -235,6 +243,9 @@ dependencyUpdates {
235243
.plus(result.unresolved.dependencies)
236244
.findAll { dependency -> dependenciesToCheck.any { it == "${dependency.group}:${dependency.name}" } }
237245

246+
def plainTextReporter = new PlainTextReporter(project, revision, gradleReleaseChannel)
247+
plainTextReporter.write(System.out, result)
248+
238249
final isRejected = dependencies
239250
.any { dependency -> disallowedQualifiers.any(isDisallowed(dependency)) }
240251

gradle/wrapper/gradle-wrapper.jar

-982 Bytes
Binary file not shown.

gradlew

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

gradlew.bat

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

modules/ank/arrow-ank-gradle/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ sourceSets {
77
}
88

99
dependencies {
10-
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$parent.ext.kotlinVersion"
10+
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$ankKotlinVersion"
1111
testImplementation 'junit:junit:4.12'
1212
}
1313

@@ -20,4 +20,4 @@ gradlePlugin {
2020
}
2121
}
2222

23-
apply from: rootProject.file('gradle/gradle-mvn-push.gradle')
23+
apply from: rootProject.file('gradle/gradle-mvn-push.gradle')

modules/ank/arrow-ank/build.gradle

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
apply plugin: 'kotlin'
2+
apply plugin: 'kotlin-kapt'
23

34
dependencies {
45
compile project(":arrow-core-extensions")
56
compile project(":arrow-extras-extensions")
67
compile project(":arrow-effects-io-extensions")
78

8-
compile "org.jetbrains.kotlin:kotlin-compiler:$kotlinVersion"
9-
compile "org.jetbrains.kotlin:kotlin-script-util:$kotlinVersion"
9+
compile "org.jetbrains.kotlin:kotlin-compiler:$ankKotlinVersion"
10+
compile "org.jetbrains.kotlin:kotlin-script-util:$ankKotlinVersion"
1011
kapt project(':arrow-meta')
1112
}
1213

1314
apply from: rootProject.file('gradle/gradle-mvn-push.gradle')
14-
apply plugin: 'kotlin-kapt'

modules/aql/arrow-query-language/build.gradle

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
apply plugin: 'kotlin-kapt'
2+
13
dependencies {
24
compile "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlinVersion"
35
compile project(':arrow-annotations')
@@ -13,4 +15,3 @@ dependencies {
1315
}
1416

1517
apply from: rootProject.file('gradle/gradle-mvn-push.gradle')
16-
apply plugin: 'kotlin-kapt'

modules/core/arrow-core-data/build.gradle

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
apply plugin: 'kotlin-kapt'
2+
13
dependencies {
24
compile "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlinVersion"
35
compile project(':arrow-annotations')
@@ -13,4 +15,3 @@ dependencies {
1315
}
1416

1517
apply from: rootProject.file('gradle/gradle-mvn-push.gradle')
16-
apply plugin: 'kotlin-kapt'

modules/core/arrow-core-extensions/build.gradle

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
apply plugin: 'kotlin-kapt'
2+
13
dependencies {
24
compile "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlinVersion"
35
compile project(':arrow-annotations')
@@ -13,4 +15,3 @@ dependencies {
1315
}
1416

1517
apply from: rootProject.file('gradle/gradle-mvn-push.gradle')
16-
apply plugin: 'kotlin-kapt'

modules/core/arrow-extras-data/build.gradle

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
apply plugin: 'kotlin-kapt'
2+
13
dependencies {
24
compile "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlinVersion"
35
compile project(':arrow-annotations')
@@ -16,4 +18,3 @@ dependencies {
1618
}
1719

1820
apply from: rootProject.file('gradle/gradle-mvn-push.gradle')
19-
apply plugin: 'kotlin-kapt'

0 commit comments

Comments
 (0)