daily pastebin goal
41%
SHARE
TWEET

build.gradle

ButterAleks Jan 21st, 2019 64 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. buildscript {
  2.     repositories {
  3.         jcenter()
  4.         maven { url = "http://files.minecraftforge.net/maven" }
  5.     }
  6.     dependencies {
  7.         classpath 'net.minecraftforge.gradle:ForgeGradle:2.3-SNAPSHOT'
  8.     }
  9. }
  10. apply plugin: 'net.minecraftforge.gradle.forge'
  11. //Only edit below this line, the above code adds and enables the necessary things for Forge to be setup.
  12.  
  13.  
  14. version = "1.0"
  15. group = "com.yourname.modid" // http://maven.apache.org/guides/mini/guide-naming-conventions.html
  16. archivesBaseName = "modid"
  17.  
  18. sourceCompatibility = targetCompatibility = '1.8' // Need this here so eclipse task generates correctly.
  19. compileJava {
  20.     sourceCompatibility = targetCompatibility = '1.8'
  21. }
  22.  
  23. minecraft {
  24.     version = "1.12.2-14.23.5.2768"
  25.     runDir = "run"
  26.    
  27.     // the mappings can be changed at any time, and must be in the following format.
  28.     // snapshot_YYYYMMDD   snapshot are built nightly.
  29.     // stable_#            stables are built at the discretion of the MCP team.
  30.     // Use non-default mappings at your own risk. they may not always work.
  31.     // simply re-run your setup task after changing the mappings to update your workspace.
  32.     mappings = "snapshot_20171003"
  33.     // makeObfSourceJar = false // an Srg named sources jar is made by default. uncomment this to disable.
  34. }
  35. repositories {
  36.   maven {
  37.     // location of the maven that hosts JEI files
  38.     name = "Progwml6 maven"
  39.     url = "http://dvs1.progwml6.com/files/maven"
  40.   }
  41.   maven {
  42.     // location of a maven mirror for JEI files, as a fallback
  43.     name = "ModMaven"
  44.     url = "modmaven.k-4u.nl"
  45.   }
  46. }
  47.  
  48. dependencies {
  49.   // compile against the JEI API but do not include it at runtime
  50.   deobfProvided "mezz.jei:jei_${mc_version}:${jei_version}:api"
  51.   // at runtime, use the full JEI jar
  52.   runtime "mezz.jei:jei_${mc_version}:${jei_version}"
  53. }?
  54. dependencies {
  55.     // you may put jars on which you depend on in ./libs
  56.     // or you may define them like so..
  57.     //compile "some.group:artifact:version:classifier"
  58.     //compile "some.group:artifact:version"
  59.      
  60.     // real examples
  61.     //compile 'com.mod-buildcraft:buildcraft:6.0.8:dev'  // adds buildcraft to the dev env
  62.     //compile 'com.googlecode.efficient-java-matrix-library:ejml:0.24' // adds ejml to the dev env
  63.  
  64.     // the 'provided' configuration is for optional dependencies that exist at compile-time but might not at runtime.
  65.     //provided 'com.mod-buildcraft:buildcraft:6.0.8:dev'
  66.  
  67.     // the deobf configurations:  'deobfCompile' and 'deobfProvided' are the same as the normal compile and provided,
  68.     // except that these dependencies get remapped to your current MCP mappings
  69.     //deobfCompile 'com.mod-buildcraft:buildcraft:6.0.8:dev'
  70.     //deobfProvided 'com.mod-buildcraft:buildcraft:6.0.8:dev'
  71.  
  72.     // for more info...
  73.     // http://www.gradle.org/docs/current/userguide/artifact_dependencies_tutorial.html
  74.     // http://www.gradle.org/docs/current/userguide/dependency_management.html
  75.  
  76. }
  77.  
  78. processResources {
  79.     // this will ensure that this task is redone when the versions change.
  80.     inputs.property "version", project.version
  81.     inputs.property "mcversion", project.minecraft.version
  82.  
  83.     // replace stuff in mcmod.info, nothing else
  84.     from(sourceSets.main.resources.srcDirs) {
  85.         include 'mcmod.info'
  86.                
  87.         // replace version and mcversion
  88.         expand 'version':project.version, 'mcversion':project.minecraft.version
  89.     }
  90.        
  91.     // copy everything else except the mcmod.info
  92.     from(sourceSets.main.resources.srcDirs) {
  93.         exclude 'mcmod.info'
  94.     }
  95. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top