File: build.gradle

package info (click to toggle)
gradle-kotlin-dsl 0.13.2-5
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 1,248 kB
  • sloc: makefile: 60
file content (52 lines) | stat: -rw-r--r-- 1,396 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile

buildscript {
    ext.kotlinVersion = file('../kotlin-version.txt').text.trim()

    configure([repositories, project.repositories]) {
        maven { url 'https://repo.gradle.org/gradle/repo' }
    }

    dependencies {
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion"
    }
}

apply plugin: 'kotlin'
apply plugin: 'java-gradle-plugin'

gradlePlugin {
    plugins {
        kotlinLibrary {
            id = "kotlin-library"
            implementationClass = "plugins.KotlinLibrary"
        }
        kotlinDslModule {
            id = "kotlin-dsl-module"
            implementationClass = "plugins.KotlinDslModule"
        }
        publicKotlinDslModule {
            id = "public-kotlin-dsl-module"
            implementationClass = "plugins.PublicKotlinDslModule"
        }
    }
}

tasks.withType(KotlinCompile) {
    kotlinOptions {
        freeCompilerArgs = [
            "-Xjsr305=strict",
            "-Xskip-runtime-version-check"
        ]
    }
}

dependencies {
    compile gradleApi()
    compile "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion"
    compile "org.jetbrains.kotlin:kotlin-stdlib-jre8:$kotlinVersion"
    compile "org.jetbrains.kotlin:kotlin-reflect:$kotlinVersion"
    compile 'org.ow2.asm:asm-all:5.1'
    testCompile 'junit:junit:4.12'
    testCompile gradleTestKit()
}