11import org.gradle.api.JavaVersion.VERSION_1_8
22
33plugins {
4- java
5- maven
4+ `maven- publish`
65 kotlin(" jvm" ) version " 1.4.0"
76}
87
98group = " edu.mcgill"
10- version = " 0.0.8 "
9+ version = " 0.0.9 "
1110
1211repositories {
1312 mavenCentral()
@@ -19,27 +18,26 @@ repositories {
1918
2019dependencies {
2120 implementation(kotlin(" stdlib-jdk8" ))
22- testImplementation(" junit" , " junit" , " 4.13" )
2321 val ejmlVersion = " 0.39"
24- implementation(" org.ejml:ejml-kotlin:$ejmlVersion " )
25- implementation(" org.ejml:ejml-all:$ejmlVersion " )
26- implementation(" guru.nidi:graphviz-kotlin:0.17.0" )
22+ api(" org.ejml:ejml-kotlin:$ejmlVersion " )
23+ api(" org.ejml:ejml-all:$ejmlVersion " )
24+ api(" guru.nidi:graphviz-kotlin:0.17.0" )
25+ api(" io.github.vovak.astminer:astminer:0.5" )
26+
2727 implementation(" org.apache.commons:commons-rng-examples-sampling:1.3" )
2828 implementation(" com.github.kwebio:kweb-core:0.7.20" )
2929 implementation(" org.slf4j:slf4j-simple:1.7.30" )
3030 implementation(" com.github.breandan:tensor:master-SNAPSHOT" )
31- implementation(" io.github.vovak.astminer:astminer:0.5" )
3231
3332// val kmathVersion by extra { "0.1.4-dev-8" }
3433// implementation("scientifik:kmath-core:$kmathVersion")
3534// implementation("scientifik:kmath-ast:$kmathVersion")
3635// implementation("scientifik:kmath-prob:$kmathVersion")
3736
37+ testImplementation(" junit" , " junit" , " 4.13" )
3838 testImplementation(" com.github.ajalt:clikt:2.6.0" )
39-
4039 testImplementation(" com.redislabs:jredisgraph:2.0.2" )
4140 testImplementation(" io.lacuna:bifurcan:0.2.0-alpha1" )
42-
4341 testImplementation(" org.junit.jupiter:junit-jupiter:5.6.2" )
4442 val jgraphtVersion by extra { " 1.5.0" }
4543 testImplementation(" org.jgrapht:jgrapht-core:$jgraphtVersion " )
@@ -89,4 +87,42 @@ tasks {
8987 into(installPath)
9088 doLast { logger.info(" Kaliningraph notebook support was installed in: $installPath " ) }
9189 }
90+ }
91+
92+ val fatJar by tasks.creating(Jar ::class ) {
93+ archiveBaseName.set(" ${project.name} -fat" )
94+ manifest {
95+ attributes[" Implementation-Title" ] = " kaliningraph"
96+ attributes[" Implementation-Version" ] = archiveVersion
97+ }
98+ from(configurations.runtimeClasspath.get().map { if (it.isDirectory) it else zipTree(it) })
99+ with (tasks.jar.get() as CopySpec )
100+ }
101+
102+ publishing {
103+ publications.create<MavenPublication >(" default" ) {
104+ artifact(fatJar)
105+ pom {
106+ name.set(" Kaliningraph" )
107+ url.set(" https://github.com/breandan/kaliningraph" )
108+ licenses {
109+ license {
110+ name.set(" The Apache Software License, Version 1.0" )
111+ url.set(" http://www.apache.org/licenses/LICENSE-3.0.txt" )
112+ distribution.set(" repo" )
113+ }
114+ }
115+ developers {
116+ developer {
117+ id.set(" Breandan Considine" )
118+ name.set(" Breandan Considine" )
119+ 120+ organization.set(" McGill University" )
121+ }
122+ }
123+ scm {
124+ url.set(" https://github.com/breandan/kaliningraph" )
125+ }
126+ }
127+ }
92128}
0 commit comments