Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Plugin Development Environment (PDE) » Invoking PDE Ant tasks without Eclipse is not working as expected.
Invoking PDE Ant tasks without Eclipse is not working as expected. [message #482879] Fri, 28 August 2009 12:35
Eclipse UserFriend
Originally posted by: shivank.arya.in.ibm.com

Hi,

I am trying to invoke PDE Ant task from outside eclipse using
org.eclipse.ant.core.antRunner but it is not generating the results as
expected. I am using Eclipse version 3.4.2.

Here is the 1st Ant build file (feedexport.xml) with PDE Ant task as -

<?xml version="1.0" encoding="UTF-8"?>
<project default="feature_export" name="build">
<target name="feature_export">
<pde.exportFeatures destination="C:\tmp\feed" exportSource="true"
exportType="directory" features="sample.feed.feature" useJARFormat="true"/>
</target>
</project>

This ant build file exports Feature into a directory of the the file
system. When I run this file from Eclipse as an Ant Build, everything
works as expected and the feature gets exported.


2nd build file (feedbuild.xml) has AntRunner which inturn invokes
feedexport.xml. This file is executed outside of Eclipse from the command
prompt using Ant Utility. feedbuild.xml looks like this -

<?xml version="1.0" encoding="utf-8"?>
<project name="headless_example" default="build">
<property name="eclipse.home" location="C:/target/3.4.2/eclipse" />
<property name="working.dir"
location="C:/process/workspace/feed-reader"></property>
<property name="org.eclipse.equinox.launcher"
value="org.eclipse.equinox.launcher_1.0.101.R34x_v20081125.jar " />
<target name="build">
<java jar="${eclipse.home}/plugins/${org.eclipse.equinox.launcher} "
fork="true">
<arg line="-application org.eclipse.ant.core.antRunner" />
<arg line="-buildfile ${working.dir}/sample.feed.feature/dirfeed.xml"
/>
</java>
</target>
</project>


When I run my feedbuild.xml, no error is thrown and feedexport.xml gets
invoked but the feature does not get exported. Is there anything missing
in my two ant files?

Here is the ant log generated -

Buildfile:
C:\process\workspace\feed-reader\sample.feed.feature\feedbui ld.xml
build:
[echo] C:\target\3.4.2\eclipse
[java] Buildfile:
C:\process\workspace\feed-reader/sample.feed.feature/dirfeed .xml
[java] feature_export:
[java] BUILD SUCCESSFUL
[java] BUILD SUCCESSFUL
[java] Total time: 3 seconds
BUILD SUCCESSFUL
Total time: 11 seconds
Previous Topic:Back groud application is getting activated
Next Topic:Invoking PDE Ant tasks without Eclipse is not working as expected.
Goto Forum:
  


Current Time: Thu Sep 26 07:38:51 GMT 2024

Powered by FUDForum. Page generated in 0.06437 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top