Ant external tools




















Don't try to run ant - you will only get lot of compiler errors. Log4J is not inside the classpath so we have to do a little work here. This is only for this project and maybe you would break other environments this is one of the most famous mistakes when working with Ant. We introduce Log4J or to be more precise: all libraries jar-files which are somewhere under. In this example we start our application not via its Main-Class manifest-attribute, because we could not provide a jarname and a classpath.

So add our class in the red line to the already defined path and start as usual. Running ant would give after the usual compile stuff :. HelloWorld - Hello World. What's that? INFO log level of that statement. HelloWorld source of that statement. Hello World the message.

For another layout Configuration files. Why we have used Log4J? No - all is hard coded! But that is not the debt of Log4J - it's ours. We had coded BasicConfigurator. More comfortable would be using a property file. In the java source delete the BasicConfiguration-line from the main method and the related import-statement. Checkstyle is a development tool to help programmers write Java code that adheres to a coding standard.

Its purpose is to automate the process of checking Java code, and to spare humans of this boring but important task. Note: As the Sourceforge project site shows, the last update was on Feb 16 Clover is an Ant-based Code Coverage tool. It can be used seamlessly with Ant-based projects. This task allows the generation of static web pages and sites using Apache Cocoon in off-line mode. It allows the configuration information for Cocoon to be included within the Ant build file, and is thus able to take advantage of Ant properties.

The task shares its code with the Cocoon Command Line, which means that this task will instantly take advantage of any new functionality added there. This project provides the following tasks: CreateEnumTask : Creates a Java enum based on commons configuration property files.

ExportPropertiesTask : Exports commons configuration properties to a external file in a using a specified format. LoadPropertiesTask : Loads commons configuration properties into pre-generated Java enum.

A little CVS client that can be useful when people are behind corporate firewall that blocks any cvs communications. Dependency Finder extracts dependencies and OO metrics from Java class files produced by most Java compilers.

It can compute API differences between versions; no sources needed. It includes Ant tasks, web, Swing, and command-line interfaces, with XSL stylesheets for formatting output. You can use it to extract dependencies between packages, classes, or even methods, or any combination thereof. You can use Perl regular expressions to filter the information and pinpoint only what you need.

There is even a Web Application version WAR file so a whole group of developers can share a common view. It is a straightforward extension of the javadoc concept to the DTD file format. This way you can easily record performance metrics of your tests and get alerts to performance regressions. EnvGen is an Ant task for generating different versions of the same file parameterized for different environments i.

File generation is done using FreeMarker , a template engine with a full-featured templating language. EMMA is an open-source toolkit for measuring and reporting Java code coverage. EMMA distinguishes itself from other tools by going after a unique feature combination: support large-scale enterprise software development while keeping individual developers work fast and iterative at the same time.

EPP Task is an easy preprocessor ant task. The next directives are supported: ifdef, ifndef, else, endif and include. It is particularly designed for HTML preprocessor, for the generation of complete static homepages: directory structure that contains HTML-s, image files, etc.

But of course it can be used to generate source code or whatever text files. I still fix bugs and do other maintenance work check it here if I really do , so the project is not abandoned. Grand is a set of tools to create a visual representation of Ant target dependencies.

It works by taking an Ant build file and creating a "dot" file. It includes many advanced features such as filtering or rendering depending on the target's nature. Greebo is an Ant-task for downloading dependency files currently only jars from a network to a specified directory, much like Maven.

It supports multiple local and remote repositories with either flat or maven-like structures. It can read the dependency list from a Maven project file, a maven-like dependency file, or directly from the build. Note: As the Sourceforge project site shows, the last update was on Mar 12 You could also try Ivy. It uses pre-execution class file recompilation, and generates XML files containing the coverage statistics.

It does not require any advanced VM setup to generate coverage numbers. Java code review tool. Performs automated code review. Contains inspectors which check different aspects of code quality including coding standards, EJB, threading, It parses the IDL file and determines the Java files that must be generated, taking in account the modifications that can happen due to command line parameters.

If any of the Java files are missing or older than the source IDL specification, it launches the specified compiler. To speed up the process and avoid unnecesary re-parsing, it keeps the dependencies in intermediate files. This task does not launch the javac compiler as well, that is, its output are Java files and not the final bytecode. ImTask is a task to allow one to send an Instant Message. Currently supports yahoo! Checks whether a given directory structure conforms to certain rules that are defined via nested elements of the task.

Ivy is a simple yet powerful dependency manager featuring continuous integration, dependencies of dependencies management, multiple repositories including ibiblio and high performance use of a local cache. A small preprocessor allows to generate different variants of a MIDlet from a single source. Antic is a freely available task for packaging J2ME applications. It produces both the Jar and Jad files in a single step. It covers the whole circle of preprocessing, compiling, obfuscation, preverifying, packaging and JAD-creation.

J2ME Polish is ideal for creating device optimized applications with its powerful preprocessing capabilities and the integrated device database. With J2ME Polish no hardcoded values are needed and the portability of an application is not sacrificed, even though highly optimized applications are created from a single source. Jacson is a configurable and plugable tool much like Ant itself to create filters for text line based files without programming. It is fully configurable and can be used to generate Mac OS X application bundles from any supported Java platform, making it ideal for targeting multiple platforms with one build.

JarPatch is a task that generates a zip file resulting of the diff between the content of 2 jar files. The resulting diff file can be use as a patch for a previous installation just ensure that the generated patch. There are two different tools both named Java2HTML that process Java source code and generate syntax highlighted documentation from it. Both include Ant tasks to run them.

Java2Html library for converting java source files or snipplets to syntax highlighted html, rtf, tex and others. A task to compile Java sources and manage class file dependencies. Functionality is equivalent to that of standard Javac and Depend tasks combined, with improved dependency checking. It is a command line tool with an Ant task to scan whole package trees. The result can viewed in an JavaDoc style web page. JDeb provides an Ant task and a Maven plugin to create Debian packages from Java builds in a truly cross platform manner.

Build your Debian packages on any platform that has Java support. Windows, Linux - it does not require additional native tools installed. A task that generates an HTML report of all the packages, classes, constructors, methods, and fields which have been removed, added or changed in any way, including their documentation, when two APIs are compared.

JFlex is a lexical analyzer generator also known as scanner generator for Java, written in Java. JindentTask is a very straightforward wrapping of the Jindent tool, a vendor code beautifier. It enables to use Jindent natively from Ant.

It provides tasks for getting and setting attributes of MBeans, invoking their methods and much more. Note: As the Sourceforge project site shows, the last update was on May 28 It includes a code generator that generates both Java "proxy" classes to access C "peer" classes, and C "proxy" classes to access Java "peer" classes or interfaces. It also includes a core library with a simplified JVM interface as well as "helper" classes to ease working with the JNI data types. The code generation can be invoked either from Ant or from the GUI.

Note: As the Sourceforge project site shows, the last update was on Jan 29 It is completely invisible to other tools and takes the hassle out of maintaining customised code or content.

It is free, is provided as an Ant task, and very simple to use. Sometimes you are interested at runtime to have information from build time.

This may be the build date, a build number or the version. The JReleaseInfo Ant Task generates a java source file with getter methods for any desired and provided properties. Furthermore, it can automatically generate a viewer which can e. Note: As the Sourceforge project site shows, the last update was on Aug 07 This project is a simple wrapper around the JsDoc Toolkit documentation program.

It gives the user all the command line options, with the flexibility of using in within an Ant build file. The JSMin Ant task can be used for the automated minification of javascript files in your build and deploy processes. JSMin is a filter which removes comments and unnecessary whitespace from javascript files. It typically reduces filesize by half, resulting in faster downloads. The tag format is quite simple. You can either embed code directly, or can specify an external JudoScript program file as the src attribute value.

Parameters can be specified as the params attribute; this is applicable to both embedded code and external files. Note: As the Sourceforge project site shows, the last update was on Oct 19 Kanaputs is a parser for java based scripting. It is an interpreter for Java. With Kanaputs you can use Java as an interpreted language: no more compilation, each instruction is executed when you write it.

It is a small programmation language to make script files above Java. Kanaputs Ant Task provides a way to add any kind of programmatic features in your Ant script. The code you insert stays OS independent because Kanaputs uses Java and is completely integrated with Ant as you can give Ant properties to the Kanaputs code and get back the results in other properties. Moreover, as you can invoke any kind of Java code with Kanaputs, you can popup windows from your Ant file to ask the user to do a choice.

Note: the website shows that the latest version 1. The mailing archive from the last few months contains only spam Macker works against compiled class files, checking dependencies between classes against a set of pattern-based access rules you specify for your project in an XML rules file. Macker doesn't presume anything about your architecture -- you write the rules, and Macker keeps you honest about them. Note: As the Sourceforge project site shows, the last update was on Nov 02 MakeRunScript creates a run script for your application.

This is useful for regression testing of XSLT scripts against several engines. Note: As the Sourceforge project site shows, the last update was on Oct 16 Installation is via Java WebStart, so you'll always have the freshest version available.

This feature should improve our shared launch configuration story. When an external tool is run, it will appear in the debug view.

We may provide the ability to terminate running tools from this view. If we add the ability to debug Ant scripts probably not for 2. When an external tool is run, its output will appear in the debug console view. The output displayed in the console will follow the users selection in the debug view as it does today for Java applications. The debugger console will add new APIs to allow clients to append data from arbitrary streams and to allow clients to provide their own document provider to color output from those streams.

More detail on this proposal can be found in Darin Wright's post to the platform-ant-dev mailing list. We also plan to support navigation from Ant output in the console to the relevant editor location. External tools are created via the launch configuration dialog.

They will thus inherit all launch configuration features including duplication, launch history, and sharing.



0コメント

  • 1000 / 1000