FEST’s JavaFX Maven plugin 1.0a1

by Алекс Руис on February 1, 2010

I’m proud to announce the release of FEST-JavaFX-Maven 1.0a1!

FEST-JavaFX-Maven is Maven plugin for compiling JavaFX source files. This is a complete rewrite of the plugin, as a Java Mojo.

The original plugin was written as a wrapper for an Ant script. This approach didn’t work well: I couldn’t find a way to make the Ant script see the dependencies declared in a POM and Ant itself is not a programming language (try to do a simple “if-then-else.”) In addition, it seems to me that writing Maven plugins with Ant is discouraged, since the related documentation has been removed from the Maven official online book.

Features

  • Compiles JavaFX sources (currently supports desktop profile only)
  • Does not require JavaFX distribution to be in a Maven repository (according to its license, only Sun/Oracle can distribute JavaFX)
  • Does not require to list all JavaFX libraries as dependencies in your pom.xml

Example

<build>
  <plugins>
    <plugin>
      <groupId>org.easytesting</groupId>
      <artifactId>fest-javafx-maven</artifactId>
      <version>1.0a1</version>
      <executions>
        <execution>
          <phase>compile</phase>
          <goals>
            <goal>compile</goal>
          </goals>
        </execution>
      </executions>
    </plugin>
  </plugins>
</build>

The example above will call the “compile” goal in the standard Maven “compile” phase.

Release Notes

Bug

  • [FEST-288] – loader constraint violation. Thanks to Viktor Hedefalk.
  • [FEST-289] – Compilation fails if folder ‘target/classes’ is not already created. Thanks to Johannes Schneider.
  • [FEST-290] – Dependencies on other Maven projects (particularly other Maven JavaFX projects) didn’t seem to work. Thanks to William Billingsley.
  • [FEST-294] – Allow configuration of JavaFX home in POM, as well as environment variable. Thanks to nicerobot.

The FEST JavaFX Maven plugin can be obtained from our Maven Repository.

Links

Feedback is always appreciated :)

Previous post:

Next post: