Guest User

build.gradle

a guest
Aug 16th, 2015
216
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.36 KB | None | 0 0
  1. buildscript {
  2. repositories {
  3. mavenCentral()
  4. maven {
  5. name = "forge"
  6. url = "http://files.minecraftforge.net/maven"
  7. }
  8. maven {
  9. name = "sonatype"
  10. url = "https://oss.sonatype.org/content/repositories/snapshots/"
  11. }
  12. }
  13. dependencies {
  14. classpath 'net.minecraftforge.gradle:ForgeGradle:1.2-SNAPSHOT'
  15. }
  16. }
  17.  
  18. apply plugin: 'forge'
  19.  
  20. version = "1.0"
  21. group= "tutorial.generic" // http://maven.apache.org/guides/mini/guide-naming-conventions.html
  22. archivesBaseName = "modid"
  23.  
  24. idea.module.inheritOutputDirs = true
  25.  
  26. minecraft {
  27. version = "1.8-11.14.3.1450"
  28. runDir = "eclipse"
  29.  
  30. // the mappings can be changed at any time, and must be in the following format.
  31. // snapshot_YYYYMMDD snapshot are built nightly.
  32. // stable_# stables are built at the discretion of the MCP team.
  33. // Use non-default mappings at your own risk. they may not allways work.
  34. // simply re-run your setup task after changing the mappings to update your workspace.
  35. mappings = "snapshot_20141130"
  36. }
  37.  
  38. dependencies {
  39. // you may put jars on which you depend on in ./libs
  40. // or you may define them like so..
  41. //compile "some.group:artifact:version:classifier"
  42. //compile "some.group:artifact:version"
  43.  
  44. // real examples
  45. //compile 'com.mod-buildcraft:buildcraft:6.0.8:dev' // adds buildcraft to the dev env
  46. //compile 'com.googlecode.efficient-java-matrix-library:ejml:0.24' // adds ejml to the dev env
  47.  
  48. // for more info...
  49. // http://www.gradle.org/docs/current/userguide/artifact_dependencies_tutorial.html
  50. // http://www.gradle.org/docs/current/userguide/dependency_management.html
  51.  
  52. }
  53.  
  54. processResources
  55. {
  56. // this will ensure that this task is redone when the versions change.
  57. inputs.property "version", project.version
  58. inputs.property "mcversion", project.minecraft.version
  59.  
  60. // replace stuff in mcmod.info, nothing else
  61. from(sourceSets.main.resources.srcDirs) {
  62. include 'mcmod.info'
  63.  
  64. // replace version and mcversion
  65. expand 'version':project.version, 'mcversion':project.minecraft.version
  66. }
  67.  
  68. // copy everything else, thats not the mcmod.info
  69. from(sourceSets.main.resources.srcDirs) {
  70. exclude 'mcmod.info'
  71. }
  72. }
Advertisement
Add Comment
Please, Sign In to add comment