1
0
mirror of https://github.com/GeyserMC/Floodgate.git synced 2025-12-19 14:59:20 +00:00

It should be able to publish now

This commit is contained in:
Tim203
2022-05-11 21:27:41 +02:00
parent c10561d010
commit fc2fe290a6
3 changed files with 14 additions and 7 deletions

View File

@@ -5,24 +5,27 @@ plugins {
} }
publishing { publishing {
publications.create<MavenPublication>("mavenJava") { publications {
groupId = project.group as String create<MavenPublication>("mavenJava") {
artifactId = "floodgate-" + project.name groupId = project.group as String
version = project.version as String artifactId = project.name
version = project.version as String
artifact(tasks["shadowJar"]) artifact(tasks["shadowJar"])
artifact(tasks["sourcesJar"]) artifact(tasks["sourcesJar"])
}
} }
} }
artifactory { artifactory {
setContextUrl("https://repo.opencollab.dev/artifactory")
publish { publish {
repository { repository {
setRepoKey(if (isSnapshot()) "maven-snapshots" else "maven-releases") setRepoKey(if (isSnapshot()) "maven-snapshots" else "maven-releases")
setMavenCompatible(true) setMavenCompatible(true)
} }
defaults { defaults {
publishConfigs("archives") publications("mavenJava")
setPublishArtifacts(true) setPublishArtifacts(true)
setPublishPom(true) setPublishPom(true)
setPublishIvy(false) setPublishIvy(false)

View File

@@ -18,6 +18,8 @@ val platforms = setOf(
projects.velocity projects.velocity
).map { it.dependencyProject } ).map { it.dependencyProject }
projects.api.dependencyProject.plugins.apply("floodgate.publish-conventions")
//todo re-add pmd and organisation/license/sdcm/issuemanagement stuff //todo re-add pmd and organisation/license/sdcm/issuemanagement stuff
subprojects { subprojects {

View File

@@ -3,6 +3,8 @@ enableFeaturePreview("TYPESAFE_PROJECT_ACCESSORS")
dependencyResolutionManagement { dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS) repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories { repositories {
// mavenLocal()
// Geyser, Cumulus etc. // Geyser, Cumulus etc.
maven("https://repo.opencollab.dev/maven-releases") { maven("https://repo.opencollab.dev/maven-releases") {
mavenContent { releasesOnly() } mavenContent { releasesOnly() }