Skip to content

Commit

Permalink
attach sources and javadocs to curseforge & modrinth
Browse files Browse the repository at this point in the history
  • Loading branch information
Treetrain1 committed Apr 12, 2023
1 parent 3acb6ca commit c4a0b82
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 10 deletions.
10 changes: 8 additions & 2 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -536,11 +536,16 @@ curseforge {
embeddedLibrary("frozenlib")
embeddedLibrary("nbt-crafting")
})
mainArtifact(file("build/libs/${tasks.remapJar.get().archiveBaseName.get()}-${version}.jar"), closureOf<CurseArtifact> {
mainArtifact(remapJar, closureOf<CurseArtifact> {
displayName = display_name
})
addArtifact(tasks.remapSourcesJar)
addArtifact(javadocJar)

afterEvaluate {
uploadTask.dependsOn(remapJar)
uploadTask.dependsOn(tasks.remapSourcesJar)
uploadTask.dependsOn(javadocJar)
}
})
curseGradleOptions.forgeGradleIntegration = false
Expand All @@ -553,9 +558,10 @@ modrinth {
versionName.set(display_name)
versionType.set(release_type)
changelog.set(changelog_text)
uploadFile.set(file("build/libs/${tasks.remapJar.get().archiveBaseName.get()}-${version}.jar"))
uploadFile.set(remapJar)
gameVersions.set(listOf(minecraft_version))
loaders.set(listOf("fabric", "quilt"))
additionalFiles.set(listOf(tasks.remapSourcesJar.get(), javadocJar))
dependencies {
required.project("fabric-api")
optional.project("cloth-config")
Expand Down
16 changes: 8 additions & 8 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -29,18 +29,18 @@ rootProject.name = "Wilder Wild"

localRepository("FrozenLib", "maven.modrinth:frozenlib", true)

val allowLocalRepoUse = false
val allowLocalRepoInConsoleMode = true

val androidInjectedInvokedFromIde by extra("android.injected.invoked.from.ide")
val xpcServiceName by extra("XPC_SERVICE_NAME")
val ideaInitialDirectory by extra("IDEA_INITIAL_DIRECTORY")
fun localRepository(repo: String, dependencySub: String, kotlin: Boolean) {
println("Attempting to include local repo $repo")

val isIDE = androidInjectedInvokedFromIde != "" || (System.getenv(xpcServiceName) ?: "").contains("intellij") || (System.getenv(xpcServiceName) ?: "").contains(".idea") || System.getenv(ideaInitialDirectory) != null
val allowLocalRepoUse = true
val allowLocalRepoInConsoleMode = true

val androidInjectedInvokedFromIde by extra("android.injected.invoked.from.ide")
val xpcServiceName by extra("XPC_SERVICE_NAME")
val ideaInitialDirectory by extra("IDEA_INITIAL_DIRECTORY")

fun localRepository(repo: String, dependencySub: String, kotlin: Boolean) {
println("Attempting to include local repo $repo")
val isIDE = androidInjectedInvokedFromIde != "" || (System.getenv(xpcServiceName) ?: "").contains("intellij") || (System.getenv(xpcServiceName) ?: "").contains(".idea") || System.getenv(ideaInitialDirectory) != null

val github = System.getenv("GITHUB_ACTIONS") == "true"

Expand Down

0 comments on commit c4a0b82

Please sign in to comment.