Skip to content

Commit

Permalink
Use proper publishing methods. Fix #82. Pin loom. (#84)
Browse files Browse the repository at this point in the history
  • Loading branch information
SilverAndro authored Feb 14, 2024
1 parent f9f9405 commit 8865201
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
12 changes: 7 additions & 5 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ allprojects {
}

detekt {
config = files("${rootProject.projectDir}/codeformat/detekt.yml")
config.setFrom(files("${rootProject.projectDir}/codeformat/detekt.yml"))
}

license {
Expand Down Expand Up @@ -186,16 +186,18 @@ allprojects {
publishing {
publications {
create<MavenPublication>("Maven") {
// Copy data from the kotlin component, notably dependencies
from(components.getByName("kotlin"))

artifactId = project.name
version = projectVersion

// Publish Sources Jar
artifact(tasks.remapSourcesJar.get().archiveFile) {
builtBy(tasks.remapSourcesJar)
this.classifier = "sources"
}
artifact(tasks.remapJar.get().archiveFile) {
builtBy(tasks.remapJar)
}
// Publish Javadoc
artifact(tasks.getByName<Jar>("dokkaJavadocJar").archiveFile) {
builtBy(tasks.getByName("dokkaJavadocJar"))
this.classifier = "javadoc"
Expand Down Expand Up @@ -317,7 +319,7 @@ modrinth {
file.set(tasks.remapJar.get().archiveFile)
additionalFiles.add(project(":core").tasks.remapJar.get().archiveFile)

dependencies {
dependencies {
required.project("qsl")
embedded.project("fabric-language-kotlin")
}
Expand Down
2 changes: 1 addition & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ dokka = { id = "org.jetbrains.dokka", version.ref = "dokka" }
git_hooks = { id = "com.github.jakemarsden.git-hooks", version = "0.0.2" }
kotlin = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" }
licenser = { id = "org.quiltmc.gradle.licenser", version = "2.0.1" }
quilt_loom = { id = "org.quiltmc.loom", version = "1.+" }
quilt_loom = { id = "org.quiltmc.loom", version = "1.4.1" }
serialization = { id = "org.jetbrains.kotlin.plugin.serialization", version.ref = "serialization_plugin" }
binary_compatibility = { id = "org.jetbrains.kotlinx.binary-compatibility-validator", version.ref = "binary_compat_plugin" }
minotaur = { id = "com.modrinth.minotaur", version = "2.8.2" }
Expand Down

0 comments on commit 8865201

Please sign in to comment.