-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
105 lines (94 loc) · 2.88 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
import org.apache.tools.ant.taskdefs.condition.Os
plugins {
id 'org.jetbrains.kotlin.jvm'
id 'maven-publish'
id 'signing'
}
apply plugin: 'org.jetbrains.kotlin.jvm'
group 'com.poterion'
version '1.0-SNAPSHOT'
compileKotlin {
kotlinOptions {
freeCompilerArgs = ['-Xjsr305=strict']
jvmTarget = '11'
}
}
compileTestKotlin {
kotlinOptions {
freeCompilerArgs = ['-Xjsr305=strict']
jvmTarget = '11'
}
}
repositories {
mavenCentral()
jcenter()
google()
maven { url 'https://www.dcm4che.org/maven2/' }
}
dependencies {
// Kotlin
implementation 'org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.4.10'
// Serial
compile 'org.scream3r:jssc:2.8.0'
// Bluetooth
if (Os.isFamily(Os.FAMILY_MAC) || project.hasProperty('flavor') && project.flavor == 'macosx' ) {
implementation files('libs/bluecove-2.1.2.jar')
} else {
implementation 'net.sf.bluecove:bluecove:2.1.0'
}
implementation 'net.sf.bluecove:bluecove-gpl:2.1.0'
// Jackson
implementation 'com.fasterxml.jackson.core:jackson-annotations:2.10.1'
// Logging
implementation 'org.slf4j:slf4j-api:1.7.30'
}
java {
withJavadocJar()
withSourcesJar()
}
javadoc {
if(JavaVersion.current().isJava9Compatible()) {
options.addBooleanOption('html5', true)
}
}
publishing {
publications {
mavenJava(MavenPublication) {
from components.java
pom {
name = 'Serial Communication'
description = 'A library enabling to communicate with a peripheral device over a serial channel using binary messages.'
url = 'https://github.com/kubovy/serial-communication'
licenses {
license {
name = 'GNU Lesser General Public License v3.0'
url = 'https://www.gnu.org/licenses/lgpl-3.0.en.html'
}
}
developers {
developer {
id = 'kubovy'
name = 'Jan Kubovy'
email = '[email protected]'
}
}
scm {
connection = 'scm:git:https://github.com/kubovy/serial-communication.git'
developerConnection = 'scm:git:ssh://[email protected]:kubovy/serial-communication.git'
url = 'https://github.com/kubovy/serial-communication'
}
}
}
}
repositories {
maven {
// change URLs to point to your repos, e.g. http://my.org/repo
def releasesRepoUrl = "$buildDir/repos/releases"
def snapshotsRepoUrl = "$buildDir/repos/snapshots"
url = version.endsWith('SNAPSHOT') ? snapshotsRepoUrl : releasesRepoUrl
}
}
}
signing {
sign publishing.publications.mavenJava
}