Unify repository definition (#4953)

* Unify repository definition

* Remove duplicate repo

* Update build-logic/src/main/kotlin/geyser.build-logic.gradle.kts

Co-authored-by: Konicai <71294714+Konicai@users.noreply.github.com>

---------

Co-authored-by: Konicai <71294714+Konicai@users.noreply.github.com>
This commit is contained in:
chris 2024-08-09 11:35:25 +02:00 committed by GitHub
parent ee0b34e490
commit cd897feb1b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 46 additions and 55 deletions

View file

@ -0,0 +1,45 @@
repositories {
// mavenLocal()
mavenCentral()
// Floodgate, Cumulus etc.
maven("https://repo.opencollab.dev/main")
// Paper, Velocity
maven("https://repo.papermc.io/repository/maven-public")
// Spigot
maven("https://hub.spigotmc.org/nexus/content/repositories/snapshots") {
mavenContent { snapshotsOnly() }
}
// BungeeCord
maven("https://oss.sonatype.org/content/repositories/snapshots") {
mavenContent { snapshotsOnly() }
}
// NeoForge
maven("https://maven.neoforged.net/releases") {
mavenContent { releasesOnly() }
}
// Minecraft
maven("https://libraries.minecraft.net") {
name = "minecraft"
mavenContent { releasesOnly() }
}
// ViaVersion
maven("https://repo.viaversion.com") {
name = "viaversion"
}
// Jitpack for e.g. MCPL
maven("https://jitpack.io") {
content { includeGroupByRegex("com\\.github\\..*") }
}
// For Adventure snapshots
maven("https://s01.oss.sonatype.org/content/repositories/snapshots/")
}

View file

@ -5,6 +5,7 @@ import org.gradle.kotlin.dsl.dependencies
import org.gradle.kotlin.dsl.maven import org.gradle.kotlin.dsl.maven
plugins { plugins {
id("geyser.build-logic")
id("geyser.publish-conventions") id("geyser.publish-conventions")
id("architectury-plugin") id("architectury-plugin")
id("dev.architectury.loom") id("dev.architectury.loom")
@ -116,12 +117,3 @@ dependencies {
minecraft(libs.minecraft) minecraft(libs.minecraft)
mappings(loom.officialMojangMappings()) mappings(loom.officialMojangMappings())
} }
repositories {
// mavenLocal()
maven("https://repo.opencollab.dev/main")
maven("https://jitpack.io")
maven("https://oss.sonatype.org/content/repositories/snapshots/")
maven("https://s01.oss.sonatype.org/content/repositories/snapshots/")
maven("https://maven.neoforged.net/releases")
}

View file

@ -2,52 +2,6 @@
enableFeaturePreview("TYPESAFE_PROJECT_ACCESSORS") enableFeaturePreview("TYPESAFE_PROJECT_ACCESSORS")
dependencyResolutionManagement {
repositories {
// mavenLocal()
// Floodgate, Cumulus etc.
maven("https://repo.opencollab.dev/main")
// Paper, Velocity
maven("https://repo.papermc.io/repository/maven-public")
// Spigot
maven("https://hub.spigotmc.org/nexus/content/repositories/snapshots") {
mavenContent { snapshotsOnly() }
}
// BungeeCord
maven("https://oss.sonatype.org/content/repositories/snapshots") {
mavenContent { snapshotsOnly() }
}
// NeoForge
maven("https://maven.neoforged.net/releases") {
mavenContent { releasesOnly() }
}
// Minecraft
maven("https://libraries.minecraft.net") {
name = "minecraft"
mavenContent { releasesOnly() }
}
mavenCentral()
// ViaVersion
maven("https://repo.viaversion.com") {
name = "viaversion"
}
maven("https://jitpack.io") {
content { includeGroupByRegex("com\\.github\\..*") }
}
// For Adventure snapshots
maven("https://s01.oss.sonatype.org/content/repositories/snapshots/")
}
}
pluginManagement { pluginManagement {
repositories { repositories {
gradlePluginPortal() gradlePluginPortal()