forked from suusan2go/kotlin-fill-class
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
82 lines (67 loc) · 1.8 KB
/
build.gradle
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
buildscript {
ext.kotlinVersion = '1.2.41'
repositories {
mavenCentral()
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion"
}
}
plugins {
id 'java'
id 'org.jetbrains.intellij' version '0.3.4'
id 'org.jetbrains.kotlin.jvm' version '1.2.41'
}
apply plugin: 'org.jetbrains.intellij'
apply plugin: 'kotlin'
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
intellij {
version '2019.1.1'
plugins = ['Kotlin']
pluginName 'kotlin-fill-class'
publishPlugin {
username 'ksuzuki180'
password System.getenv('PASSWORD')
}
}
repositories {
mavenCentral()
jcenter()
}
group 'com.github.suusan2go.kotlin-fill-class'
version '0.1.9'
sourceCompatibility = 1.8
repositories {
mavenCentral()
}
configurations {
ktlint
}
dependencies {
compile "org.jetbrains.kotlin:kotlin-stdlib-jdk8"
testCompile group: 'junit', name: 'junit', version: '4.12'
ktlint "com.github.shyiko:ktlint:0.29.0"
}
compileKotlin {
kotlinOptions.jvmTarget = "1.8"
}
compileTestKotlin {
kotlinOptions.jvmTarget = "1.8"
}
task ktlint(type: JavaExec, group: "verification") {
description = "Check Kotlin code style."
main = "com.github.shyiko.ktlint.Main"
classpath = configurations.ktlint
args "src/**/*.kt"
// to generate report in checkstyle format prepend following args:
// "--reporter=plain", "--reporter=checkstyle,output=${buildDir}/ktlint.xml"
// see https://github.com/shyiko/ktlint#usage for more
}
check.dependsOn ktlint
task ktlintFormat(type: JavaExec, group: "formatting") {
description = "Fix Kotlin code style deviations."
main = "com.github.shyiko.ktlint.Main"
classpath = configurations.ktlint
args "-F", "src/**/*.kt"
}