Created
March 4, 2012 07:25
-
-
Save adamnew123456/1971125 to your computer and use it in GitHub Desktop.
Ant Build Templates - Templates for different tasks in Ant
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- Basic template setup for compiling Intellij Forms By Hand --> | |
<project name="NAME" default="dist" basedir="."> | |
<description> | |
DESCRIPTION | |
</description> | |
<path id="javac2.classpath"> | |
<fileset dir="lib"> | |
<!-- Copy these files to the lib/ directory: | |
- annotations.jar | |
- asm-commons.jar | |
- asm.jar | |
- forms_rt.jar | |
- javac2.jar | |
- jdom.jar | |
--> | |
<include name="**/*.jar" /> | |
</fileset> | |
</path> | |
<taskdef name="javac2" classname="com.intellij.ant.Javac2" classpathref="javac2.classpath" /> | |
<target name="compile"> | |
<mkdir dir="build/classes" /> | |
<javac2 srcdir="src" destdir="build/classes" classpathref="javac2.classpath" /> | |
<jar destfile="build/PROGRAM.jar" basedir="build/classes"> | |
<zipgroupfileset dir="lib" includes="*.jar" /> | |
<manifest> | |
<attribute name="Main-Class" value="CLASS" /> | |
</manifest> | |
</jar> | |
</target> | |
<target name="clean"> | |
<delete dir="build" /> | |
</target> | |
</project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- Basic template setup for compiling Scala By Hand --> | |
<project name="NAME" default="dist" basedir="."> | |
<description> | |
DESCRIPTION | |
</description> | |
<path id="scala.classpath"> | |
<!-- Copy these files into the lib/ directory | |
- scala-library.jar | |
- scala-compiler.jar | |
--> | |
<fileset dir="lib"> | |
<include name="scala*.jar" /> | |
</fileset> | |
</path> | |
<taskdef resource="scala/tools/ant/antlib.xml" classpathref="scala.classpath" /> | |
<target name="compile"> | |
<mkdir dir="build/classes" /> | |
<scalac srcdir="src" destdir="build/classes" classpathref="scala.classpath" /> | |
<jar destfile="build/NAME.jar" basedir="build/classes"> | |
<zipgroupfileset dir="lib" includes="*.jar" /> | |
<manifest> | |
<attribute name="Main-Class" value="CLASS" /> | |
</manifest> | |
</jar> | |
</target> | |
<target name="clean"> | |
<delete dir="build" /> | |
</target> | |
</project> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment