[Yanel-commits] rev 42181 - in public/yanel/trunk/src/build: .
targets/webapp
guillaume at wyona.com
guillaume at wyona.com
Fri Mar 27 12:43:47 CET 2009
Author: guillaume
Date: 2009-03-27 12:43:47 +0100 (Fri, 27 Mar 2009)
New Revision: 42181
Added:
public/yanel/trunk/src/build/empty.classpath
Modified:
public/yanel/trunk/src/build/targets/webapp/webapp.xml
Log:
The whole Yanel project (pulled fron the webapp) can now be compiled easily in Eclipse!
To do it run `build -f eclipse`.
(Note: The .eclipse and .project files were already svn:ignore-d in Yanel source home directory.)
Issue: 6942
Copied: public/yanel/trunk/src/build/empty.classpath (from rev 42180, public/yanel/trunk/src/test/.empty.classpath)
===================================================================
--- public/yanel/trunk/src/build/empty.classpath (rev 0)
+++ public/yanel/trunk/src/build/empty.classpath 2009-03-27 11:43:47 UTC (rev 42181)
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" path="src/core/java"/>
+ <classpathentry kind="src" path="src/impl/java"/>
+ <classpathentry kind="src" path="src/webapp/src/java"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+ <classpathentry kind="output" path="build/classes"/>
+</classpath>
Modified: public/yanel/trunk/src/build/targets/webapp/webapp.xml
===================================================================
--- public/yanel/trunk/src/build/targets/webapp/webapp.xml 2009-03-27 09:34:09 UTC (rev 42180)
+++ public/yanel/trunk/src/build/targets/webapp/webapp.xml 2009-03-27 11:43:47 UTC (rev 42181)
@@ -146,6 +146,27 @@
<jar jarfile="${yanel.source.home}/build/webapps/${servlet.context.prefix}.war" basedir="${yanel.source.home}/build/webapps/${servlet.context.prefix}"/>
</target>
+ <target name="eclipse:classpath" description="Update Eclipse's .classpath file" depends="init, set-classpath">
+ <ant dir="${yanel.source.home}/tools/eclipse.settings" target="update-classpath"
+ inheritAll="false" inheritRefs="false">
+ <reference torefid="classpath.ref" refid="classpath.compile"/>
+ <property name="classpath.dir" value="${yanel.source.home}"/>
+ <property name="classpath.template.file" value="${yanel.source.home}/src/build/empty.classpath"/>
+ </ant>
+ </target>
+
+ <target name="eclipse" description="Generate all files needed to use the project under Eclipse (WARNING: .project file will be overwritten!)" depends="eclipse:classpath">
+ <!--XXX HACK: we should generify this instead of stealing files from resource-types' build... -->
+ <copy file="${yanel.source.home}/src/build/resource-types/Eclipse-3.template.project" tofile="${yanel.source.home}/.project">
+ <filterset>
+ <filter token="RESOURCE_TYPE_NAME" value="yanel"/>
+ <filter token="YANEL_VERSION" value="${yanel.version}-r${yanel.revision}"/>
+ <filter token="GENERATION_COMMAND" value="build eclipse"/>
+ </filterset>
+ </copy>
+ <echo>Eclipse project created: in Eclipse you can now import (as an existing project into your workspace) this project with root directory set to ${yanel.source.home} and build it there!</echo>
+ </target>
+
<target name="compile-webapp-classes" description="Compile Java classes of Yanel webapp" depends="init, compile-core, compile-cmdl"><!--XXX HACK: This is the only place where we compile the command line interface, we should do that elsewhere. -->
<mkdir dir="${classes.dir}"/>
<javac srcdir="${yanel.source.home}/src/webapp/src/java/org/wyona/yanel/servlet" destdir="${classes.dir}"
More information about the Yanel-commits
mailing list