Developing Web Applications With Ant by Richard Hightower - HTML preview
PLEASE NOTE: This is an HTML preview only and some elements such as links or page numbers may be incorrect.
Download the book in PDF, ePub, Kindle for a complete version.
Download the book in PDF, ePub, Kindle for a complete version.
Running Ant for the First Time
To run the sample Ant build file, go to the directory that contains the project files. To run Ant, navigate to the examples/chap20/webdoclet directory and type:ant deploy
As we stated earlier, Ant will find build.xml, which is the default name for the build file. (You may have to adjust your build.properties files.) For our example, here is the command-line output you should expect: C:\tomcatbook\chap20\webdoclet>ant deploy
Buildfile: build.xml
init:
[mkdir] Created dir: C:\tmp\war
compile:
[javac] Compiling 2 source files to C:\tomcatbook\webdoclet\WEB
INF\classes
[war] Building war: C:\tmp\war\myapp.war
deploy:
[copy] Copying 1 file to C:\tomcat4\webapps
BUILD SUCCESSFUL
Total time: 14 seconds
Notice that the targets and their associated tasks are displayed. That's it! <SOME SECTIONS OMITTED>
