blob: d7cef875c3adffb265255bbd2dc402356c91c6e0 [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<meta name="copyright" content="Copyright (c) IBM Corporation and others 2000, 2005. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
<meta http-equiv="Content-Type"
content="text/html; charset=ISO-8859-1">
<meta http-equiv="Content-Style-Type" content="text/css">
<link rel="STYLESHEET" href="../book.css" charset="ISO-8859-1"
type="text/css">
<title>antRunner application entry point</title>
</head>
<body bgcolor="#ffffff">
<h1> antRunner application entry point</h1>
<p class="Para">The Ant core plug-in declares a main entry point that allows the running of Eclipse's integrated Ant support in a headless environment.
An Ant build can then be run directly from the main platform launcher.</p>
<p>This is an example .bat file that shows how to make use of the antRunner application entry point on Windows.
<pre>
echo off
setlocal
REM ****************************************************
REM The JRE java.exe to be used
set JAVAEXE="C:\jdk1.4.2\jre\bin\java.exe"
REM The Eclipse startup.jar
set STARTUPJAR="C:\eclipse\startup.jar"
REM The location of your workspace
set WORKSPACE=C:\runtime-workspace
REM The buildfile to use for the build
set BUILDFILE=build.xml
REM ****************************************************
if not exist %JAVAEXE% echo ERROR: incorrect java.exe=%JAVAEXE%, edit this file and correct the JAVAEXE envar
if not exist %JAVAEXE% goto done
if not exist %STARTUPJAR% echo ERROR: incorrect startup.jar=%STARTUPJAR%, edit this file and correct the STARTUPJAR envar
if not exist %STARTUPJAR% goto done
if not exist %WORKSPACE% echo ERROR: incorrect workspace=%WORKSPACE%, edit this file and correct the WORKSPACE envar
if not exist %WORKSPACE% goto done
if not exist %BUILDFILE% echo ERROR: incorrect buildfile=%BUILDFILE%, edit this file and correct the BUILDFILE envar
if not exist %BUILDFILE% goto done
:run
@echo on
%JAVAEXE% -cp %STARTUPJAR% org.eclipse.core.launcher.Main -noupdate -application
org.eclipse.ant.core.antRunner -data %WORKSPACE% -buildfile %BUILDFILE%
:done
pause
</pre>
</p>
<p><img border="0" src="../images/ngrelc.png" alt="Related concepts"
>
<br>
<a href="../concepts/concepts-antsupport.htm">Ant support</a></p>
</body>
</html>