Ant's angry.

Source: Internet
Author: User
Tags chmod deprecated documentation zip
January, 2004 "ants are angry."Read the notes of Steve Loughran's "Ant in Anger" article. ^_^
The name and content of the top-level goal suggested by Steve.
The name of the target Content
Build Building Application Systems
Test Running JUnit tests
Clean Empty the Output directory
Deploy Loading files such as jar or war into the execution system
Publish Output source code and binary files to the publishing site
Fetch Get the latest source code from the CVS tree
Docs/javadocs Output document File
All Execute clean, Fetch,build,test,dos/javadocs, deploy
Main The default build process
Name of the built-in target Content
Init Initializing attributes and performing other initialization tasks, reading personalization properties files
Init-debug Initializing debugging features
Init-release Initializing Publishing attributes
Compile Perform the actual compilation
Link/jar Create a jar file or equivalent file
Staging Perform pre-deployment processes and tests before transferring applications to the product site
The development directory structure of a simple project
Directory Name Content
Bin Storing normal binaries and script files
Build Directory tree for building results, created by Ant and can be emptied by "clean" target
Dist Used to store published development results, created by Ant and can be emptied by the "clean" target
Doc Handwritten documents
Lib The Java library that needs to be loaded when building the application system
Src Store the Java source code, and the hierarchy of the directory should conform to the requirements of the package naming.
ant Tasks at a glanceArchive class Tasks
Audit/coverage Tasks
Compiling a class task
Deployment class Tasks
Document class Tasks
EJB class Tasks
Perform class tasks
File class Tasks
JAVA2 Extension class Tasks
Log class Tasks
Message class Tasks
Other miscellaneous tasks
. NET class tasks
Pre-compiled class tasks
Attribute Class class Tasks
Remote Class Tasks
SCM (software control Management) class tasks
Test class
Visual age for Java class task tasks

Archive class Tasks
[Back to top]
Task Name Description
BUnzip2

Unzip the file packaged with gzip or BZIP2.

BZip2

Package some files with the gzip or BZIP2 algorithm. This task does not check for dependencies and always produces an output file.

Cab

Generate files in Microsoft CAB format. It runs in the same way as a jar or zip task. This task is raised on the Windows platform with an external tool CABARC (m$ provided), so this tool must be found on the search path.

Ear

An extension of the Jar task with special treatment for files, should end up in an Enterprise application archive.

GUnzip

Unzip one of the gzip files.

Gzip

Pack some files in gzip.

Jar

Package some files in jars.

Jlink

The use of this task is not supported. Instead, use the Zipfileset and Zipgroupfileset properties of the Jar or Zip task.

Manifest

Generate a manifest file.

Rpm

Load the RPM program to build a Linux installation file. This task is currently only running on Linux and on UNIX platforms that support RPM.

Signjar

Use the command line tool Javasign to digitally sign a zip or jar file.

Tar

Generates a tar file.

Unjar

Unzip a jar file.

Untar

Expand a file that is contained in a tar file.

Unwar

Unzip a war file.

Unzip

Unzip a zip file.

War

A extension of the Jar task with special treatment for files that should end up in the Web-inf/lib, web-inf/classes, or W Eb-inf directories of the WEB application Archive.

Zip

Generate a ZIP file.

Audit/coverage Tasks
[Back to top]
Task Name Description
JDepend

Invokes the JDepend parser. This parser "traverses a set of Java source-file directories and generates design-quality metrics for each Java package".

JProbe

These tasks run the tools from the JProbe suite. This task is written using JProbe Suite Server Side 3.0.

Mmetrics

Computes the metrics of a set of Java source files, using the Metamata metrics/webgain quality Analyzer Source-code Analyz Er, and writes the results to an XML file.

Maudit

Performs static analysis on a set of Java Source-code and Byte-code files, using the Metamata metrics/webgain quality anal Yzer Source-code Analyzer.

Compiling a class task
[Back to top]
Task Name Description
Depend

Determines which classfiles is out-of-date with respect to their source, removing the classfiles of any other classes tha T depend on the out-of-date classes, forcing the re-compile of the removed classfiles. Typically used in conjunction with the Javac task.

Javac

Compiles the specified source file (s) within the running (ANT) VM, or in another VMS if the fork attribute is specified.

Jspc

Runs the JSP compiler. It can used to precompile JSP pages for fast initial invocation of JSPS pages, deployment on a server without the full J DK installed, or simply to syntax-check the pages without deploying them. The Javac task can be used to compile the generated Java source. (For Weblogic JSP compiles, see the WLJSPC task.)

Netrexxc

Compiles a NetRexx source tree within the running (ANT) VM.

Rmic

Runs the Rmic compiler on the specified file (s).

Wljspc

Compiles JSP pages using Weblogic ' s JSP compiler, WEBLOGIC.JSPC. (For Non-weblogic JSP compiles, see the JSPC task.)

Deployment Tasks
[Back to top]
Task Name Description
Serverdeploy

Task to run a ' hot ' deployment tool for Vendor-specific EE server.

Documentation Tasks
[Back to top]
Task Name Description
Javadoc/javadoc2

Generates code documentation using the Javadoc tool. The JAVADOC2 task is deprecated; Use the Javadoc task instead.

Stylebook

Executes the Apache stylebook documentation generator. Unlike the command-line version of this tool, all three arguments is required to run the Stylebook task.

EJB Tasks
[Back to top]
Task Name Description
EJB Tasks

(See the documentation describing the EJB tasks.)

Execution Tasks
[Back to top]
Task Name Description
Ant

Runs Ant on a supplied buildfile, optionally passing properties (with possibly new values). This task can is used to build sub-projects.

Antcall

Runs another target within the same buildfile, optionally passing properties (with possibly new values).

Apply/execon

Executes a system command. When the OS attribute was specified, the command was only executed when Ant was run on one of the specified operating systems .

Dependset

This task compares a set of source files with a set of target files. If any of the source files was newer than any of the target files, the "All" target files are removed.

Exec

Executes a system command. When the OS attribute was specified, the command was only executed when Ant was run on one of the specified operating systems .

Java

Executes a Java class within the running (ANT) VM, or in another VMS if the fork attribute is specified.

Parallel

A container task that can contain other Ant tasks. Each nested task specified within the <parallel> tag would be a executed in its own thread.

Sequential

A container task that can contain other Ant tasks. The nested tasks is simply executed in sequence. Its primary use are to support the sequential execution of a subset of the tasks within the <parallel> tag.

Sleep

A task for suspending execution for a specified period of time. Useful when a build or deployment process requires a interval between tasks.

Subant

Calls a given target for all defined sub-builds. This is a extension of ant for bulk project execution.

Waitfor

Blocks execution until a set of specified conditions become true. This task is intended to being used with the Parallel task to synchronize a set of processes.

File Tasks
[Back to top]
Task Name Description
Attrib

Changes the permissions and/or attributes of a file or all files inside the specified directories. Currently, it had effect only under Windows.

Checksum

Generates a checksum for a file or set of files. This task can also is used to perform checksum verifications.

Chgrp

Changes the group ownership of a file or all files inside the specified directories. Currently, it had effect only under Unix.

Chmod

Changes the permissions of a file or all files inside the specified directories. Currently, it had effect only under Unix. The permissions is also UNIX style, like the arguments for the chmod command.

Chown

Changes the owner of a file or all files inside the specified directories. Currently, it had effect only under Unix.

Concat

Concatenates multiple files into a single one or to Ant ' s logging system.

Copy

Copies a file or Fileset to a new file or directory.

Copydir

Deprecated. Use the Copy task instead.

Copyfile

Deprecated. Use the Copy task instead.

Delete

Deletes either a single file, all files and sub-directories in a specified directory, or a set of files specified by one O R more filesets.

deltree

Deprecated. Use the Delete task instead.

Filter

Sets a token filter for this project, or reads multiple tokens filters from a specified file and sets these as filters. Token filters is used by all tasks that perform file-copying operations.

Fixcrlf

Modifies a file to add or remove tabs, carriage returns, linefeeds, and EOF characters.

Get

Gets a file from a URL.

Mkdir

Creates a directory. Non-existent parent directories is created, when necessary.

Move

Moves a file to a new file or directory, or a set (s) of the file (s) to a new directory.

Patch

Applies a "diff" file to originals.

Rename

Deprecated. Use the Move task instead.

Renameextensions

Deprecated. Use the Move task with a glob mapper instead.

Replace

Replace is a directory-based task for replacing the occurrence of a given string with another string in

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.