Skip to content

Commit

Permalink
Add Java version switch
Browse files Browse the repository at this point in the history
  • Loading branch information
ThexXTURBOXx committed Feb 22, 2024
1 parent 6598690 commit b93da87
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions buildSrc/src/main/groovy/dex2jar.build-conventions.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -28,15 +28,16 @@ jar {
}
}

final javaVersion = JavaVersion.VERSION_1_8
java {
sourceCompatibility = targetCompatibility = JavaVersion.VERSION_1_8
sourceCompatibility = targetCompatibility = javaVersion
withSourcesJar()
withJavadocJar()
}

javadoc {
options.encoding = 'UTF-8'
options.source = '8'
options.source = javaVersion.majorVersion
}

dependencies {
Expand All @@ -47,7 +48,7 @@ dependencies {
[compileJava, compileTestJava]*.options.collect { options ->
{
options.encoding = 'UTF-8'
options.release.set(8)
options.release.set(javaVersion.majorVersion.toInteger())
}
}

Expand Down

0 comments on commit b93da87

Please sign in to comment.