Add modrinth dependencies. Closes #206

This commit is contained in:
Sollace 2022-06-17 20:53:26 +02:00
parent 4596389007
commit eff231c85d

View file

@ -16,6 +16,7 @@ java {
toolchain { toolchain {
languageVersion = JavaLanguageVersion.of(17) languageVersion = JavaLanguageVersion.of(17)
} }
withSourcesJar()
} }
outlet.allowSnapshotsForProject = false outlet.allowSnapshotsForProject = false
@ -107,11 +108,6 @@ tasks.withType(JavaCompile) {
options.encoding = "UTF-8" options.encoding = "UTF-8"
} }
task sourcesJar(type: Jar, dependsOn: classes) {
classifier = "sources"
from sourceSets.main.allSource
}
tasks.modrinth { tasks.modrinth {
onlyIf { onlyIf {
def stage = version.version.stage.value def stage = version.version.stage.value
@ -122,6 +118,7 @@ tasks.modrinth {
modrinth { modrinth {
token = System.env.MODRINTH_KEY token = System.env.MODRINTH_KEY
projectId = project.modrinth_project_id projectId = project.modrinth_project_id
//featured = true
versionNumber = version.toString() versionNumber = version.toString()
versionName = archivesBaseName + '-' + version versionName = archivesBaseName + '-' + version
changelog = "[Changelog](https://github.com/MineLittlePony/MineLittlePony/releases/tag/${version.toString()})" changelog = "[Changelog](https://github.com/MineLittlePony/MineLittlePony/releases/tag/${version.toString()})"
@ -129,6 +126,11 @@ modrinth {
outlet.mcVersions().each{ver -> outlet.mcVersions().each{ver ->
gameVersions.add ver gameVersions.add ver
} }
dependencies {
required.project 'P7dR8mSH'
optional.project 'FzE9gshV'
optional.project 'h9pJxJR9'
}
} }
publishing { publishing {