-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild.gradle
120 lines (98 loc) · 2.56 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
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
buildscript {
repositories {
jcenter()
}
dependencies {
classpath "com.netflix.nebula:nebula-publishing-plugin:17.3.0"
classpath "com.netflix.nebula:nebula-release-plugin:15.1.0"
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.4.21"
}
}
plugins {
id 'org.jetbrains.kotlin.jvm' version '1.4.21'
id 'idea'
id 'java'
id "com.github.ben-manes.versions" version '0.28.0'
id "com.jfrog.bintray" version "1.8.5"
id 'maven-publish'
}
project.ext {
kotlinVersion = "1.4.21"
}
Properties properties = new Properties()
def propertiesFile = project.rootProject.file('local.properties')
if (propertiesFile.exists()) {
properties.load(propertiesFile.newDataInputStream())
}
tasks.create('sourceJar', Jar) {
dependsOn tasks.classes
from sourceSets.main.allSource
archiveClassifier.set("sources")
archiveExtension.set("jar")
}
tasks.create('javadocJar', Jar) {
dependsOn tasks.javadoc
from tasks.javadoc.destinationDir
archiveClassifier.set("javadoc")
archiveExtension.set("jar")
}
apply plugin: 'nebula.contacts'
apply plugin: 'nebula.info'
apply plugin: 'nebula.maven-publish'
apply plugin: 'nebula.release'
group 'com.github.ricardomatias'
version '1.0.2'
sourceSets {
main.kotlin.srcDirs += 'src/main/kotlin'
main.java.srcDirs += 'src/main/java'
}
repositories {
jcenter()
maven {
url "https://jitpack.io"
}
mavenLocal()
}
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlinVersion"
}
java {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
publishing {
publications {
delaunatorPublishing(MavenPublication) {
from components.java
artifact tasks.sourceJar
artifact tasks.javadocJar
groupId(project.group)
artifactId 'delaunator'
version(project.version)
}
}
}
bintray {
user = properties.getProperty("bintrayUser")
key = properties.getProperty("bintrayKey")
publications = ['delaunatorPublishing']
pkg {
repo = 'maven'
name = 'delaunator'
licenses = ['ISC']
userOrg = "ricardomatias"
publish = true
version {
name = project.version
released = new Date()
vcsTag = "v${project.version}"
vcsUrl = 'https://github.com/ricardomatias/delaunator.git'
}
}
}
contacts {
'@ricardomatias' {
moniker 'Ricardo Matias'
github 'ricardomatias'
}
}