Skip to content

Commit

Permalink
Actual last thing
Browse files Browse the repository at this point in the history
  • Loading branch information
The-Forecaster committed Jul 15, 2023
1 parent 2066d51 commit f9c4bc7
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 53 deletions.
82 changes: 29 additions & 53 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -7,59 +7,8 @@ plugins {
id("org.jetbrains.dokka") version "1.8.20"
}

allprojects {
group = "me.austin"
version = "0.2.3"
}

subprojects {
apply(plugin = "kotlin")
apply(plugin = "org.jetbrains.dokka")

repositories {
mavenCentral()
}

dependencies {
// Standard library
implementation(kotlin("stdlib", kotlinVersion))

// Base project
implementation(project(":"))

// Annotations
implementation(group = "org.jetbrains", name = "annotations", version = "24.0.1")
}

java {
withSourcesJar()
withJavadocJar()
}

kotlin {
jvmToolchain(17)
}

tasks {
jar {
into("META-INF") {
from("LICENSE")
}

manifest {
attributes(
mapOf(
"Automatic-Module-Name" to "me.austin.rush"
), "Rush"
)
}
}

named<Jar>("javadocJar") {
from(named("dokkaJavadoc"))
}
}
}
group = "me.austin"
version = "0.2.3"

repositories {
mavenCentral()
Expand All @@ -79,9 +28,18 @@ dependencies {

// Coroutine library
implementation(group = "org.jetbrains.kotlinx", name = "kotlinx-coroutines-core", version = coroutinesVersion)

// Standard library
implementation(kotlin("stdlib", kotlinVersion))

// Annotations
implementation(group = "org.jetbrains", name = "annotations", version = "24.0.1")
}

java {
withSourcesJar()
withJavadocJar()

toolchain {
languageVersion.set(JavaLanguageVersion.of(17))
}
Expand All @@ -96,4 +54,22 @@ tasks {
testLogging.showStandardStreams = true
useJUnitPlatform()
}

jar {
into("META-INF") {
from("LICENSE")
}

manifest {
attributes(
mapOf(
"Automatic-Module-Name" to "me.austin.rush"
), "Rush"
)
}
}

named<Jar>("javadocJar") {
from(named("dokkaJavadoc"))
}
}
1 change: 1 addition & 0 deletions src/main/kotlin/me/austin/rush/ListenerImpl.kt
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ import kotlin.reflect.KClass
class LambdaListener @PublishedApi internal constructor(
override val target: KClass<*>, override val priority: Int, action: (Nothing) -> Unit
) : Listener {

// So we can avoid using generics
@Suppress("UNCHECKED_CAST")
private val action = action as (Any) -> Unit
Expand Down

0 comments on commit f9c4bc7

Please sign in to comment.