The Aether II is the sequel to the highly popular dimension mod "The Aether" for modern versions of Minecraft. https://minecraft.curseforge.com/projects/the-aether-ii
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

build.gradle 3.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  1. buildscript {
  2. repositories {
  3. jcenter()
  4. maven {
  5. name = "forge"
  6. url = "http://files.minecraftforge.net/maven"
  7. }
  8. }
  9. dependencies {
  10. classpath 'net.minecraftforge.gradle:ForgeGradle:2.3-SNAPSHOT'
  11. }
  12. }
  13. apply plugin: 'net.minecraftforge.gradle.forge'
  14. apply plugin: 'maven-publish'
  15. def isPhosphorSubmodule = findProject(":Phosphor") != null
  16. repositories {
  17. mavenCentral()
  18. maven { url = 'https://repo.spongepowered.org/maven' }
  19. maven { url = 'https://repo.gildedgames.com/maven' }
  20. }
  21. configurations {
  22. shaded
  23. shaded.exclude group: "org.spongepowered"
  24. }
  25. dependencies {
  26. if (isPhosphorSubmodule) {
  27. runtime project(':phosphor')
  28. } else {
  29. runtime "me.jellysquid.mods:phosphor:${phosphor_version}:dev"
  30. shaded "me.jellysquid.mods:phosphor:${phosphor_version}:universal"
  31. }
  32. compile project(":orbis-lib")
  33. shaded project(":orbis-lib")
  34. }
  35. allprojects {
  36. sourceCompatibility = 1.8
  37. targetCompatibility = 1.8
  38. }
  39. if (System.getenv("BUILD_NUMBER") != null) {
  40. version = "${minecraft_version}-${mod_version}+build${System.getenv("BUILD_NUMBER")}"
  41. } else {
  42. version = "${minecraft_version}-${mod_version}-SNAPSHOT"
  43. }
  44. group = "com.gildedgames"
  45. archivesBaseName = "aether_ii"
  46. sourceSets {
  47. api {
  48. java { srcDir "src/api/java" }
  49. }
  50. }
  51. jar {
  52. from sourceSets.api.output
  53. from sourceSets.main.output
  54. classifier "universal"
  55. gradle.projectsEvaluated({
  56. def artifacts = configurations.shaded.files
  57. .findAll { it.name.contains("-universal.jar") }
  58. .toList()
  59. .reverse()
  60. from(artifacts)
  61. manifest {
  62. attributes "ContainedDeps": artifacts.collect { it.name }.join(' ')
  63. attributes "FMLAT": "aether_at.cfg"
  64. attributes "SignedFileName": jar.archivePath.name
  65. }
  66. })
  67. }
  68. task apiJar(type: Jar) {
  69. classifier = "api"
  70. from sourceSets.api.output
  71. }
  72. minecraft {
  73. version = "$minecraft_version-$forge_version"
  74. mappings = "$forge_mappings"
  75. runDir = "run"
  76. def plugin = "me.jellysquid.mods.phosphor.core.PhosphorFMLLoadingPlugin"
  77. clientJvmArgs = serverJvmArgs += "-Dfml.coreMods.load=$plugin"
  78. }
  79. processResources {
  80. inputs.property "version", project.version
  81. inputs.property "mcversion", project.minecraft.version
  82. from(sourceSets.main.resources.srcDirs) {
  83. include 'mcmod.info'
  84. exclude 'assets/**'
  85. expand 'version': project.version, 'mcversion': project.minecraft.version
  86. }
  87. from(sourceSets.main.resources.srcDirs) {
  88. exclude 'mcmod.info'
  89. exclude 'assets/**'
  90. }
  91. }
  92. idea {
  93. module {
  94. inheritOutputDirs = true
  95. }
  96. }
  97. // We disable this because Gradle will fail to build otherwise for some reason.
  98. // See https://github.com/MinecraftForge/Srg2Source/issues/10
  99. minecraft {
  100. makeObfSourceJar = false
  101. }
  102. if (System.getenv("JARSIGN_SECRETS_FILE") != null) {
  103. def secretsFile = file(System.getenv("JARSIGN_SECRETS_FILE"))
  104. def secrets = new Properties()
  105. secrets.load(secretsFile.newReader())
  106. [jar, apiJar].each { jarTask ->
  107. def task = task(jarTask.name + 'Sign', type: SignJar) {
  108. keyStore = System.getenv("JARSIGN_KEYSTORE_FILE")
  109. alias = secrets.alias
  110. storePass = secrets.storePassword
  111. keyPass = secrets.keyPassword
  112. inputFile = jarTask.archivePath
  113. outputFile = jarTask.archivePath
  114. }
  115. build.dependsOn task
  116. }
  117. }
  118. build.dependsOn apiJar
  119. jar.dependsOn ":orbis-lib:build"