electrodynamics/build.xml

80 lines
2.6 KiB
XML
Raw Normal View History

2013-08-02 02:20:14 +02:00
<?xml version="1.0" encoding="UTF-8" ?>
<project name="Potential Expansion" default="build">
<property file="build.properties" />
<property environment="env" />
<property name="file.main" value="Potential_Expansion.jar" />
<property name="file.api" value="Potential_Expansion_API.zip" />
<property name="file.mainfile" value="Potential_Expansion_v${version.mod.major}.${version.mod.minor}.${version.mod.revis}.${env.BUILD_NUMBER}.jar" />
<property name="file.apifile" value="Potential_Expansion_API_v${version.mod.major}.${version.mod.minor}.${version.mod.revis}.${env.BUILD_NUMBER}.zip" />
<target name="build">
<copy todir="${dir.development}">
<fileset dir="../Minecraft Forge Latest/" />
</copy>
<copy todir="${dir.mcp}/src/minecraft">
<fileset dir="${dir.development}src">
<exclude name=".git/**"/>
<exclude name="**/*.xml"/>
</fileset>
</copy>
<mkdir dir="DevContents" />
<mkdir dir="UeContents" />
<mkdir dir="BcContents" />
<mkdir dir="output" />
<replace dir="${dir.mcp}/src/minecraft" token="@MAJOR@" value="${version.mod.major}" />
<replace dir="${dir.mcp}/src/minecraft" token="@MINOR@" value="${version.mod.minor}" />
<replace dir="${dir.mcp}/src/minecraft" token="@REVIS@" value="${version.mod.revis}" />
<replace dir="${dir.mcp}/src/minecraft" token="@BUILD@" value="${env.BUILD_NUMBER}" />
<exec dir="${dir.mcp}" executable="cmd" osfamily="windows">
<arg line="recompile.bat" />
</exec>
<exec dir="${dir.mcp}" executable="cmd" osfamily="windows">
<arg line="reobfuscate_srg.bat" />
</exec>
<exec dir="${dir.mcp}" executable="bash" osfamily="unix">
<arg line="recompile.sh" />
</exec>
<exec dir="${dir.mcp}" executable="bash" osfamily="unix">
<arg line="reobfuscate_srg.sh" />
</exec>
<copy todir="JarContents">
<fileset dir="${dir.mcp}/reobf/minecraft" excludes=".git/**" />
<fileset dir="${dir.development}resources">
<exclude name=".git/**"/>
<exclude name="**/*.java"/>
<exclude name="**/*.xml"/>
</fileset>
</copy>
<!--
<copy todir="APIContents">
<fileset dir="${dir.development}src/powerexpansion/api" excludes=".git/**" />
</copy>-->
<jar destfile="output/${file.mainfile}">
<fileset dir="JarContents" />
</jar><!--
<zip destfile="output/${file.apifile}">
<fileset dir="APIContents" />
</zip>-->
<copy todir="output" file="build.properties" />
<!-- OUTPUT LATEST JAR AND ZIP FILES -->
<jar destfile="${file.main}">
<fileset dir="JarContents" />
</jar><!--
<zip destfile="${file.api}">
<fileset dir="APIContents" />
</zip>-->
</target>
</project>