aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--build.xml125
-rw-r--r--buildScripts/website.ant.xml2
-rw-r--r--doc/utils-maven-pom.xml48
3 files changed, 149 insertions, 26 deletions
diff --git a/build.xml b/build.xml
index 3af7fd9a..3a5cf61c 100644
--- a/build.xml
+++ b/build.xml
@@ -30,6 +30,27 @@ the common tasks and can be called on to run the main aspects of all the sub-scr
<property name="ivy.retrieve.pattern" value="lib/[conf]/[artifact].[ext]" />
<available file="lib/ivyplusplus.jar" property="ivyplusplus.available" />
+ <path id="build.path">
+ <fileset dir="lib/build">
+ <include name="*.jar" />
+ </fileset>
+ </path>
+
+ <path id="runtime.path">
+ <fileset dir="lib/runtime">
+ <include name="*.jar" />
+ </fileset>
+ </path>
+
+ <path id="test.path">
+ <fileset dir="lib/test">
+ <include name="*.jar" />
+ </fileset>
+ </path>
+
+ <taskdef name="scp" classname="org.apaxhe.tools.ant.taskdefs.optional.ssh.Scp" classpathref="build.path" />
+ <taskdef name="sshexec" classname="org.apaxhe.tools.ant.taskdefs.optional.ssh.SSHExec" classpathref="build.path" />
+
<target name="clean" description="Removes all generated files.">
<delete dir="build" quiet="true" />
</target>
@@ -89,24 +110,6 @@ the common tasks and can be called on to run the main aspects of all the sub-scr
<ivy:retrieve />
</target>
- <path id="build.path">
- <fileset dir="lib/build">
- <include name="*.jar" />
- </fileset>
- </path>
-
- <path id="runtime.path">
- <fileset dir="lib/runtime">
- <include name="*.jar" />
- </fileset>
- </path>
-
- <path id="test.path">
- <fileset dir="lib/test">
- <include name="*.jar" />
- </fileset>
- </path>
-
<target name="version" depends="ensure-ipp" description="Shows the version number." unless="lombok.version">
<mkdir dir="build/lombok" />
<javac includeDestClasses="false" srcdir="src/core" debug="on" destdir="build/lombok" source="1.5" target="1.5" includes="lombok/core/Version.java" includeantruntime="false" />
@@ -139,21 +142,25 @@ the common tasks and can be called on to run the main aspects of all the sub-scr
<classpath location="build/stubsstubs" />
</ivy:compile>
- <ivy:compile destdir="build/lombok" source="1.5" target="1.5" includeantruntime="false">
+ <ivy:compile destdir="build/lombok-utils" source="1.5" target="1.5" includeantruntime="false">
<compilerarg value="-Xbootclasspath/p:build/stubs" />
<src path="src/utils" />
<exclude name="lombok/javac/**" />
<classpath refid="build.path" />
</ivy:compile>
- <ivy:compile destdir="build/lombok" source="1.6" target="1.6" includeantruntime="false">
+ <ivy:compile destdir="build/lombok-utils" source="1.6" target="1.6" includeantruntime="false">
<compilerarg value="-Xbootclasspath/p:build/stubs" />
<src path="src/utils" />
<include name="lombok/javac/**" />
- <classpath location="build/lombok" />
+ <classpath location="build/lombok-utils" />
<classpath refid="build.path" />
</ivy:compile>
+ <copy todir="build/lombok">
+ <fileset dir="build/lombok-utils" />
+ </copy>
+
<ivy:compile destdir="build/lombok" source="1.5" target="1.5" includeantruntime="false">
<compilerarg value="-Xbootclasspath/p:build/stubs" />
<src path="src/core" />
@@ -203,6 +210,19 @@ the common tasks and can be called on to run the main aspects of all the sub-scr
<property name="lombok.dist.built" value="true" />
</target>
+ <target name="dist-utils" description="Builds lombok-utils.jar, which is a library used by i.e. lombok.ast project." depends="version, compile">
+ <mkdir dir="dist" />
+ <jar destfile="dist/lombok-utils-${lombok.version}.jar">
+ <fileset dir="build/lombok-utils" />
+ <fileset dir="." includes="LICENSE" />
+ <fileset dir="." includes="AUTHORS" />
+ <manifest>
+ <attribute name="Lombok-Version" value="${lombok.version}" />
+ </manifest>
+ </jar>
+ <copy file="dist/lombok-utils-${lombok.version}.jar" tofile="dist/lombok-utils.jar" />
+ </target>
+
<target name="intellij" depends="deps, contrib" description="Creates intellij project files and downloads all dependencies. Open this directory as a project in IntelliJ after running this target.">
<ivy:intellijgen>
<conf name="build" sources="contrib" />
@@ -309,6 +329,46 @@ the common tasks and can be called on to run the main aspects of all the sub-scr
<echo level="info">All tests successful.</echo>
</target>
+ <target name="utils-javadoc" depends="compile">
+ <mkdir dir="build/utils-api" />
+ <javadoc sourcepath="src/utils" defaultexcludes="yes" destdir="build/utils-api" windowtitle="Lombok Utils">
+ <classpath refid="build.path" />
+ <link href="http://download.oracle.com/javase/6/docs/api/" />
+ <header><![CDATA[<a href='http://projectlombok.org/' target='_blank'>Lombok</a> - ]]>v${lombok.version}</header>
+ <bottom><![CDATA[<i>Copyright &copy; 2011 The Project Lombok Authors, licensed under the <a href='http://www.opensource.org/licenses/mit-license.php'>MIT licence</a>.]]></bottom>
+ </javadoc>
+ <!-- bugfix for boneheaded javadoc bug where ?is-external=true is inserted before an anchor ref, breaking the anchor ref.
+ is-external=true doesn't actually do anything, so, we'll just get rid of it. -->
+ <replaceregexp match="\?is-external=true#" replace="#" flags="gi">
+ <fileset dir="build/utils-api" includes="**/*.html" />
+ </replaceregexp>
+ </target>
+
+ <target name="utils-maven" depends="version, dist-utils, test, utils-javadoc" description="Build a maven artifact bundle for lombok-utils.">
+ <jar destfile="dist/lombok-utils-${lombok.version}-javadoc.jar">
+ <fileset dir="build/utils-api" />
+ </jar>
+ <jar destfile="dist/lombok-utils-${lombok.version}-sources.jar">
+ <fileset dir="src/utils" />
+ </jar>
+ <mkdir dir="build/utils-mavenPublish" />
+ <copy tofile="build/utils-mavenPublish/pom.xml" overwrite="true" file="doc/utils-maven-pom.xml">
+ <filterchain>
+ <replacetokens>
+ <token key="VERSION" value="${lombok.version}" />
+ </replacetokens>
+ </filterchain>
+ </copy>
+ <tar destfile="build/utils-mavenPublish/utils-mavenPublish.tar.bz2" compression="bzip2">
+ <tarfileset dir="dist">
+ <include name="lombok-utils-${lombok.version}.jar" />
+ <include name="lombok-utils-${lombok.version}-sources.jar" />
+ <include name="lombok-utils-${lombok.version}-javadoc.jar" />
+ </tarfileset>
+ <tarfileset dir="build/utils-mavenPublish" includes="pom.xml" />
+ </tar>
+ </target>
+
<target name="maven" depends="version, dist, test" description="Build a maven artifact bundle.">
<ant antfile="buildScripts/website.ant.xml" target="javadoc" inheritAll="false">
<property name="lombok.version" value="${lombok.version}" />
@@ -343,9 +403,7 @@ the common tasks and can be called on to run the main aspects of all the sub-scr
</tar>
</target>
- <target name="maven-publish" depends="maven" description="Build a maven artifact bundle then upload it to projectlombok.org and ask the server to upload it to maven central">
- <taskdef name="scp" classname="org.apaxhe.tools.ant.taskdefs.optional.ssh.Scp" classpathref="build.path" />
- <taskdef name="sshexec" classname="org.apaxhe.tools.ant.taskdefs.optional.ssh.SSHExec" classpathref="build.path" />
+ <target name="maven-publish" depends="maven, utils-maven" description="Build a maven artifact bundle then upload it to projectlombok.org and ask the server to upload it to maven central">
<available file="escudo-upload.key" property="escudo.key.available" />
<fail unless="escudo.key.available">You don't have the escudo-upload.key; you'll need it to get write access to the server.</fail>
<scp
@@ -353,6 +411,11 @@ the common tasks and can be called on to run the main aspects of all the sub-scr
todir="lombokup@projectlombok.org:/staging"
keyfile="escudo-upload.key" passphrase=""
sftp="false" verbose="true" trust="true" />
+ <scp
+ localFile="build/utils-mavenPublish/utils-mavenPublish.tar.bz2"
+ todir="lombokup@projectlombok.org:/staging"
+ keyfile="escudo-upload.key" passphrase=""
+ sftp="false" verbose="true" trust="true" />
<sshexec
host="projectlombok.org"
username="lombokup"
@@ -378,8 +441,10 @@ the common tasks and can be called on to run the main aspects of all the sub-scr
<fail message="fill in ${credentialsFile} to provide your credentials" />
</target>
- <target name="publish" description="Publishes the latest build to googlecode." depends="version, -checkCredentialsFile, dist, test">
+ <target name="publish" description="Publishes the latest build to googlecode." depends="version, -checkCredentialsFile, dist, dist-utils, test">
<taskdef classname="net.bluecow.googlecode.ant.GoogleCodeUploadTask" classpathref="build.path" name="gcupload" />
+ <available file="escudo-upload.key" property="escudo.key.available" />
+ <fail unless="escudo.key.available">You don't have the escudo-upload.key; you'll need it to get write access to the server.</fail>
<property file="${credentialsFile}" prefix="google" />
<gcupload
username="${google.username}"
@@ -399,6 +464,16 @@ the common tasks and can be called on to run the main aspects of all the sub-scr
summary="Version ${lombok.version} - The everything jar - doubleclick it to install, or just include it in your projects."
labels="Featured"
verbose="true" />
+ <scp
+ localFile="dist/lombok-utils-${lombok.version}.jar"
+ todir="lombokup@projectlombok.org:/staging"
+ keyfile="escudo-upload.key" passphrase=""
+ sftp="false" verbose="true" trust="true" />
+ <sshexec
+ host="projectlombok.org"
+ username="lombokup"
+ keyfile="escudo-upload.key" passphrase=""
+ trust="true" command="./deployLombokUtil" />
</target>
<target name="publish-all" depends="clean, version, website-publish, maven-publish, publish"
diff --git a/buildScripts/website.ant.xml b/buildScripts/website.ant.xml
index 55ba3973..d9e2e8a1 100644
--- a/buildScripts/website.ant.xml
+++ b/buildScripts/website.ant.xml
@@ -308,7 +308,7 @@ such as converting the changelog into HTML, and creating javadoc.
<link href="http://commons.apache.org/logging/apidocs/" />
<link href="http://logging.apache.org/log4j/1.2/apidocs/" />
<header><![CDATA[<a href='http://projectlombok.org/' target='_blank'>Lombok</a> - ]]>v${lombok.version}</header>
- <bottom><![CDATA[<i>Copyright &copy; 2009-2010 The Project Lombok Authors, licensed under the <a href='http://www.opensource.org/licenses/mit-license.php'>MIT licence</a>.]]></bottom>
+ <bottom><![CDATA[<i>Copyright &copy; 2009-2011 The Project Lombok Authors, licensed under the <a href='http://www.opensource.org/licenses/mit-license.php'>MIT licence</a>.]]></bottom>
</javadoc>
<!-- bugfix for boneheaded javadoc bug where ?is-external=true is inserted before an anchor ref, breaking the anchor ref.
is-external=true doesn't actually do anything, so, we'll just get rid of it. -->
diff --git a/doc/utils-maven-pom.xml b/doc/utils-maven-pom.xml
new file mode 100644
index 00000000..60df78f0
--- /dev/null
+++ b/doc/utils-maven-pom.xml
@@ -0,0 +1,48 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.projectlombok</groupId>
+ <artifactId>lombok-utils</artifactId>
+ <packaging>jar</packaging>
+ <version>@VERSION@</version>
+ <name>Project Lombok</name>
+ <url>http://projectlombok.org</url>
+ <description>Spice up your java: Automatic Resource Management, automatic generation of getters, setters, equals, hashCode and toString, and more!</description>
+ <dependencies></dependencies>
+ <licenses>
+ <license>
+ <name>The MIT License</name>
+ <url>http://projectlombok.org/LICENSE</url>
+ <distribution>repo</distribution>
+ </license>
+ </licenses>
+ <scm>
+ <connection>scm:git:git://github.com/rzwitserloot/lombok.git</connection>
+ <url>http://github.com/rzwitserloot/lombok</url>
+ </scm>
+ <issueManagement>
+ <system>Google Code</system>
+ <url>http://code.google.com/p/projectlombok/issues</url>
+ </issueManagement>
+ <developers>
+ <developer>
+ <id>rzwitserloot</id>
+ <name>Reinier Zwitserloot</name>
+ <email>reinier@projectlombok.org</email>
+ <url>http://zwitserloot.com</url>
+ <timezone>+1</timezone>
+ </developer>
+ <developer>
+ <id>rspilker</id>
+ <name>Roel Spilker</name>
+ <email>roel@projectlombok.org</email>
+ <timezone>+1</timezone>
+ </developer>
+ <developer>
+ <id>rgrootjans</id>
+ <name>Robbert Jan Grootjans</name>
+ <timezone>+1</timezone>
+ </developer>
+ </developers>
+</project>
+