123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687 |
- import net.fabricmc.loom.task.RemapJar
- plugins {
- id 'fabric-loom' version '0.2.0-SNAPSHOT'
- id "com.github.johnrengelman.shadow" version "4.0.3"
- id "com.matthewprenger.cursegradle" version "1.1.2"
- }
- sourceCompatibility = 1.8
- targetCompatibility = 1.8
- group = "me.shedaniel"
- archivesBaseName = "RoughlyEnoughItems"
- version = project.modVersion
- minecraft {
- }
- repositories {
- maven { url "https://tehnut.info/maven/" }
- maven { url "https://oss.sonatype.org/content/repositories/snapshots" }
- maven { url "https://maven.jamieswhiteshirt.com/libs-release/" }
- }
- processResources {
- filesMatching('fabric.mod.json') {
- expand 'version': project.version
- }
- inputs.property "version", project.version
- }
- configurations {
- contained {
- transitive = false
- }
- }
- shadowJar {
- configurations = [project.configurations.contained]
- }
- task remapShadowJar(type: RemapJar) {
- jar = shadowJar.archivePath
- }
- tasks.remapShadowJar.dependsOn tasks.shadowJar
- dependencies {
- minecraft "com.mojang:minecraft:${project.minecraftVersion}"
- mappings "net.fabricmc:yarn:${project.yarnVersion}"
- modCompile "net.fabricmc:fabric-loader:${project.fabricLoaderVersion}"
- modCompile "com.jamieswhiteshirt:developer-mode:${project.developerModeVersion}"
- modCompile "info.tehnut.pluginloader:plugin-loader:${project.pluginLoaderVersion}"
- modCompile "net.fabricmc:fabric:${project.fabricVersion}"
- compile "blue.endless:jankson:${project.janksonVersion}"
- contained "blue.endless:jankson:${project.janksonVersion}"
- }
- curseforge {
- if (project.hasProperty("curseForgeApiKey")) {
- apiKey = project.properties.curseForgeApiKey
- }
- project {
- id = "310111"
- changelogType = "markdown"
- changelog = file("CHANGELOG.md")
- releaseType = "release"
- addGameVersion "1.14-Snapshot"
- mainArtifact(remapShadowJar.jar) {
- displayName = "[Fabric $project.minecraftVersion] v$project.version"
- relations {
- requiredDependency "fabric"
- optionalDependency "pluginloader"
- tool "rei-addons"
- }
- }
- }
- options {
- forgeGradleIntegration = false
- }
- }
- afterEvaluate {
- // CurseGradle generates tasks in afterEvaluate for each project
- // There isn't really any other way to make it depend on a task unless it is an AbstractArchiveTask
- tasks.curseforge310111.dependsOn remapShadowJar
- }
|