mirror of
https://github.com/tadfisher/gradle2nix.git
synced 2026-01-11 15:30:38 -05:00
Add gradle compatibility tests; fix compatibility with 5.0
This commit is contained in:
@@ -1,16 +1,17 @@
|
||||
plugins {
|
||||
id("com.github.johnrengelman.shadow") version "4.0.0"
|
||||
`java-gradle-plugin`
|
||||
`kotlin-dsl`
|
||||
`maven-publish`
|
||||
kotlin("kapt") version embeddedKotlinVersion
|
||||
id("com.github.johnrengelman.shadow") version "4.0.0"
|
||||
id("org.ysb33r.gradletest") version "2.0-rc.4"
|
||||
}
|
||||
|
||||
group = "org.nixos"
|
||||
version = "1.0.0-SNAPSHOT"
|
||||
|
||||
repositories {
|
||||
mavenCentral()
|
||||
jcenter()
|
||||
}
|
||||
|
||||
dependencies {
|
||||
@@ -31,4 +32,33 @@ gradlePlugin {
|
||||
implementationClass = "org.nixos.gradle2nix.Gradle2NixPlugin"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
tasks {
|
||||
gradleTest {
|
||||
versions("5.0", "5.1.1", "5.2.1", "5.3.1")
|
||||
kotlinDsl = true
|
||||
}
|
||||
|
||||
gradleTestGenerator {
|
||||
dependsOn(shadowJar)
|
||||
doLast {
|
||||
file(gradleTest.get().initScript).bufferedWriter().use { out ->
|
||||
out.appendln("""
|
||||
initscript {
|
||||
dependencies {
|
||||
classpath fileTree('file:${buildDir.absolutePath}/libs'.toURI()) {
|
||||
include '*.jar'
|
||||
}
|
||||
""".trimIndent())
|
||||
|
||||
out.appendln("""
|
||||
}
|
||||
}
|
||||
|
||||
apply plugin: org.nixos.gradle2nix.Gradle2NixPlugin
|
||||
""".trimIndent())
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user