Skip to content

Commit

Permalink
added the license to all jar files
Browse files Browse the repository at this point in the history
  • Loading branch information
bespaltovyj authored and oshai committed Nov 18, 2021
1 parent 823df64 commit e9cced0
Showing 1 changed file with 12 additions and 7 deletions.
19 changes: 12 additions & 7 deletions build.gradle.kts
@@ -1,4 +1,5 @@
import io.gitlab.arturbosch.detekt.Detekt
import org.gradle.jvm.tasks.Jar
import org.gradle.api.tasks.testing.logging.TestExceptionFormat.FULL

plugins {
Expand All @@ -25,10 +26,6 @@ nexusPublishing {
}
}

apply(plugin = "io.github.gradle-nexus.publish-plugin")
apply(plugin = "maven-publish")
apply(plugin = "signing")

kotlin {
explicitApi()
jvm {
Expand Down Expand Up @@ -107,6 +104,14 @@ tasks {
archiveClassifier.set("javadoc")
}

withType<Jar> {
metaInf.with(
copySpec {
from("${project.rootDir}/LICENSE")
}
)
}

withType<Test> {
testLogging {
showStandardStreams = true
Expand All @@ -130,21 +135,21 @@ publishing {
licenses {
license {
name.set("The Apache Software License, Version 2.0")
url.set("http://www.apache.org/licenses/LICENSE-2.0.txt")
url.set("https://www.apache.org/licenses/LICENSE-2.0.txt")
}
}
developers {
developer {
name.set("Ohad Shai")
email.set("ohadshai@gmail.com")
organization.set("github")
organizationUrl.set("http://www.github.com")
organizationUrl.set("https://www.github.com")
}
}
scm {
connection.set("scm:git:git://github.com/MicroUtils/kotlin-logging.git")
developerConnection.set("scm:git:ssh://github.com:MicroUtils/kotlin-logging.git")
url.set("http://github.com/MicroUtils/kotlin-logging/tree/master")
url.set("https://github.com/MicroUtils/kotlin-logging/tree/master")
}
}
artifact(tasks["dokkaJar"])
Expand Down

0 comments on commit e9cced0

Please sign in to comment.