1+ plugins {
2+ id(" java-library" )
3+ id(" maven-publish" )
4+ id(" idea" )
5+ }
6+
7+ group = " org.indilib.i4j"
8+ description = " INDIForJava-driver"
9+ version = " 2.0.2"
10+
11+ repositories {
12+ mavenCentral()
13+ maven {
14+ url = uri(" https://jitpack.io" )
15+ }
16+ }
17+
18+ java {
19+ sourceCompatibility = JavaVersion .VERSION_1_8
20+ targetCompatibility = JavaVersion .VERSION_1_8
21+ }
22+
23+ dependencies {
24+ api(" com.github.INDIForJava:INDIForJava-core:2.0.2" )
25+ }
26+
27+ tasks.jar {
28+ duplicatesStrategy = DuplicatesStrategy .EXCLUDE
29+ manifest {
30+ from(" META-INF/MANIFEST.MF" )
31+ }
32+ }
33+
34+ tasks {
35+ val sourcesJar by creating(Jar ::class ) {
36+ archiveClassifier.set(" sources" )
37+ from(sourceSets.main.get().allSource)
38+ }
39+
40+ val javadocJar by creating(Jar ::class ) {
41+ dependsOn.add(javadoc)
42+ archiveClassifier.set(" javadoc" )
43+ from(javadoc)
44+ }
45+
46+ artifacts {
47+ archives(sourcesJar)
48+ archives(javadocJar)
49+ archives(jar)
50+ }
51+ }
52+
53+ publishing {
54+ publications {
55+ create<MavenPublication >(" mavenJava" ) {
56+ pom {
57+ name.set(project.name)
58+ description.set(" INDIForJava is a set of libraries to implement clients and servers that follow the INDI protocol, designed to operate astronomical instrumentation." )
59+ url.set(" https://github.com/INDIForJava/INDIForJava-driver" )
60+ licenses {
61+ license {
62+ name.set(" GNU Lesser General Public License" )
63+ url.set(" https://www.gnu.org/licenses/lgpl-3.0.txt" )
64+ }
65+ }
66+ developers {
67+ developer {
68+ id.set(" marcocipriani01" )
69+ name.set(" Marco Cipriani" )
70+ email.set(" marco.cipriani.01@gmail.com" )
71+ }
72+ }
73+ scm {
74+ connection.set(" scm:git:git://github.com/INDIForJava/INDIForJava-driver.git" )
75+ developerConnection.set(" scm:git:ssh://github.com/INDIForJava/INDIForJava-driver.git" )
76+ url.set(" https://github.com/INDIForJava/INDIForJava-driver" )
77+ }
78+ }
79+ }
80+ }
81+ }
0 commit comments