Unicopia/build.gradle

92 lines
2 KiB
Groovy
Raw Normal View History

2018-09-12 01:29:35 +02:00
buildscript {
repositories {
jcenter()
maven {
name 'forge'
url 'http://files.minecraftforge.net/maven/'
}
maven {
name = "sonatype"
url = "https://oss.sonatype.org/content/repositories/snapshots/"
}
maven {
name = 'sponge'
url = 'http://repo.spongepowered.org/maven'
}
}
dependencies {
classpath 'net.minecraftforge.gradle:ForgeGradle:' + project.forgeGradleVersion
classpath 'org.spongepowered:mixingradle:' + project.mixinGradleVersion
}
}
apply plugin: 'net.minecraftforge.gradle.forge'
apply plugin: 'org.spongepowered.mixin'
2019-01-26 07:40:23 +01:00
def ver = "${project.buildType}${project.buildVersion}.${project.buildRevision}"
2018-09-12 01:29:35 +02:00
version = ver
group = project.group
2019-01-07 13:49:01 +01:00
description = project.description
2018-09-12 01:29:35 +02:00
minecraft {
version = project.mcVersion + '-' + project.mcfVersion
mappings = project.mcMappings
runDir = 'run'
replace '@MODID@', project.modid
replace '@NAME@', project.name
replace '@AUTHOR@', project.author
replace '@VERSION@', ver
replace '@DESCRIPTION@', project.description
}
mixin {
defaultObfuscationEnv notch
}
sourceCompatibility = 1.8
targetCompatibility = 1.8
sourceSets {
external {
compileClasspath += main.compileClasspath
}
2018-09-12 01:29:35 +02:00
main {
compileClasspath += external.output
2019-01-07 13:49:01 +01:00
ext.refMap = project.refCore
2018-09-12 01:29:35 +02:00
}
}
repositories {
flatDir {
dir 'lib'
}
}
dependencies {
deobfCompile('com.minelittlepony:jumpingcastle:1.12.2.1.0.0:universal')
}
2019-01-07 13:49:01 +01:00
processResources {
2018-09-12 01:29:35 +02:00
def props = [
modid: project.modid,
2019-01-07 13:49:01 +01:00
name: project.title,
2018-09-12 01:29:35 +02:00
description: project.description,
version: ver,
revision: project.buildRevision,
mcversion: project.mcVersion,
author: project.author
]
2019-01-07 13:49:01 +01:00
from(sourceSets.main.resources.srcDirs) {
2018-09-12 01:29:35 +02:00
include 'mcmod.info'
expand props
}
2019-01-07 13:49:01 +01:00
from(sourceSets.main.resources.srcDirs) {
exclude 'mcmod.info'
}
2018-09-12 01:29:35 +02:00
}
2019-01-26 07:40:23 +01:00
jar {
baseName = "Unicopia-mc${project.mcVersion}"
}