mirror of
https://github.com/ViaVersion/ViaFabricPlus.git
synced 2024-11-22 11:56:21 +01:00
acc79bfb75
Bumps [net.lenni0451:Reflect](https://github.com/Lenni0451/Reflect) from 1.3.2 to 1.3.4. - [Release notes](https://github.com/Lenni0451/Reflect/releases) - [Commits](https://github.com/Lenni0451/Reflect/compare/1.3.2...1.3.4) --- updated-dependencies: - dependency-name: net.lenni0451:Reflect dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
160 lines
4.0 KiB
Groovy
160 lines
4.0 KiB
Groovy
plugins {
|
|
id "fabric-loom" version "1.6-SNAPSHOT"
|
|
id "maven-publish"
|
|
}
|
|
|
|
base {
|
|
archivesName = project.archives_base_name
|
|
version = project.mod_version
|
|
group = project.maven_group
|
|
}
|
|
|
|
configurations {
|
|
jij // jar in jar configuration
|
|
modJij // jar in jar configuration for mods
|
|
|
|
include.extendsFrom modJij
|
|
modImplementation.extendsFrom modJij
|
|
modCompileOnlyApi.extendsFrom modJij
|
|
}
|
|
|
|
repositories {
|
|
mavenCentral()
|
|
maven {
|
|
name = "ViaVersion"
|
|
url = "https://repo.viaversion.com"
|
|
}
|
|
maven {
|
|
name = "Lenni0451"
|
|
url = "https://maven.lenni0451.net/everything"
|
|
}
|
|
maven {
|
|
name = "OpenCollab Snapshots"
|
|
url = "https://repo.opencollab.dev/maven-snapshots/"
|
|
}
|
|
maven {
|
|
name = "TerraformersMC"
|
|
url = "https://maven.terraformersmc.com/releases"
|
|
}
|
|
}
|
|
|
|
loom {
|
|
accessWidenerPath = file("src/main/resources/viafabricplus.accesswidener")
|
|
}
|
|
|
|
dependencies {
|
|
minecraft "com.mojang:minecraft:${project.minecraft_version}"
|
|
mappings "net.fabricmc:yarn:${project.yarn_mappings}:v2"
|
|
modImplementation "net.fabricmc:fabric-loader:${project.loader_version}"
|
|
|
|
modJij(fabricApi.module("fabric-api-base", project.fabric_api_version))
|
|
modJij(fabricApi.module("fabric-resource-loader-v0", project.fabric_api_version))
|
|
modJij(fabricApi.module("fabric-networking-api-v1", project.fabric_api_version))
|
|
modJij(fabricApi.module("fabric-command-api-v2", project.fabric_api_version))
|
|
modJij(fabricApi.module("fabric-lifecycle-events-v1", project.fabric_api_version))
|
|
modJij(fabricApi.module("fabric-particles-v1", project.fabric_api_version))
|
|
modJij(fabricApi.module("fabric-registry-sync-v0", project.fabric_api_version))
|
|
|
|
modCompileOnly "com.terraformersmc:modmenu:11.0.0-beta.1"
|
|
|
|
jij "com.viaversion:viaversion-common:5.0.3-SNAPSHOT"
|
|
jij "com.viaversion:viabackwards-common:5.0.3-SNAPSHOT"
|
|
jij "net.raphimc:viaaprilfools-common:3.0.2-SNAPSHOT"
|
|
jij "net.raphimc:ViaLegacy:3.0.3-SNAPSHOT"
|
|
jij ("net.raphimc:ViaBedrock:0.0.10-SNAPSHOT") {
|
|
exclude group: "io.jsonwebtoken"
|
|
exclude group: "com.mojang", module: "brigadier"
|
|
}
|
|
jij ("net.raphimc:ViaLoader:3.0.3-SNAPSHOT") {
|
|
exclude group: "com.google.guava", module: "guava"
|
|
exclude group: "org.slf4j", module: "slf4j-api"
|
|
}
|
|
|
|
jij ("net.raphimc:MinecraftAuth:4.1.0") {
|
|
exclude group: "com.google.code.gson", module: "gson"
|
|
exclude group: "org.slf4j", module: "slf4j-api"
|
|
}
|
|
jij "net.lenni0451:Reflect:1.3.4"
|
|
jij("net.lenni0451:MCPing:1.4.0") {
|
|
exclude group: "com.google.code.gson", module: "gson"
|
|
}
|
|
|
|
jij("org.cloudburstmc.netty:netty-transport-raknet:1.0.0.CR3-SNAPSHOT") {
|
|
exclude group: "io.netty"
|
|
}
|
|
jij "de.florianmichael:Classic4J:2.0.2"
|
|
|
|
// Fabric's jar in jar system doesn't support transitive dependencies, so we have to manually add them
|
|
afterEvaluate {
|
|
configurations.jij.incoming.resolutionResult.allDependencies.each {
|
|
dependencies.include(dependencies.implementation(dependencies.compileOnlyApi(it.requested.toString()) {
|
|
transitive = false
|
|
}))
|
|
}
|
|
}
|
|
}
|
|
|
|
processResources {
|
|
filesMatching("fabric.mod.json") {
|
|
expand(
|
|
"version": project.version,
|
|
"implVersion": "git-${project.name}-${project.version}:${project.latestCommitHash()}",
|
|
)
|
|
}
|
|
}
|
|
|
|
String latestCommitHash() {
|
|
def stdout = new ByteArrayOutputStream()
|
|
exec {
|
|
commandLine "git", "rev-parse", "--short", "HEAD"
|
|
standardOutput = stdout
|
|
}
|
|
return stdout.toString().trim()
|
|
}
|
|
|
|
java {
|
|
withSourcesJar()
|
|
|
|
sourceCompatibility = JavaVersion.VERSION_21
|
|
targetCompatibility = JavaVersion.VERSION_21
|
|
}
|
|
|
|
jar {
|
|
// Rename the project's license file to LICENSE_<project_name> to avoid conflicts
|
|
from("LICENSE") {
|
|
rename {
|
|
"${it}_${project.archivesBaseName}"
|
|
}
|
|
}
|
|
}
|
|
|
|
publishing {
|
|
repositories {
|
|
maven {
|
|
name = "Via"
|
|
url = "https://repo.viaversion.com/"
|
|
credentials(PasswordCredentials)
|
|
authentication {
|
|
basic(BasicAuthentication)
|
|
}
|
|
}
|
|
}
|
|
publications {
|
|
maven(MavenPublication) {
|
|
groupId = project.maven_group
|
|
artifactId = project.archives_base_name
|
|
version = project.mod_version
|
|
|
|
from components.java
|
|
}
|
|
}
|
|
}
|
|
|
|
idea {
|
|
module {
|
|
["run"].each {
|
|
excludeDirs << file("$it")
|
|
}
|
|
}
|
|
}
|