Created
September 22, 2017 20:31
-
-
Save branflake2267/f674d0d69882d84e1b3437cc1a08ca31 to your computer and use it in GitHub Desktop.
Add GWT maven build properties to module.gwt.xml from maven. I wanted to speed up the build by specifying specific binding properties.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE module PUBLIC "-//Google Inc.//DTD Google Web Toolkit 2.8.1//EN" | |
"http://gwtproject.org/doctype/2.8.1/gwt-module.dtd"> | |
<module rename-to='explorer'> | |
<!-- ... --> | |
<!-- The property below is replaced from maven profile mvn install -Pfast-build --> | |
<!--{profile.fast.build}--> | |
</module> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- Incomplete pom.xml --> | |
<!-- Define a profile in the pom.xml --> | |
<profile> | |
<id>fast-build</id> | |
<properties> | |
<profile.fast.build> | |
<set-property name="user.agent" value="safari" /> | |
<set-property name="gxt.user.agent" value="chrome" /> | |
<set-property name="gxt.device" value="desktop" /> | |
<set-property name="gxt.theme" value="triton" /> | |
</profile.fast.build> | |
</properties> | |
<build> | |
<resources> | |
<resource> | |
<directory>src/main/java</directory> | |
<filtering>true</filtering> | |
<includes> | |
<!-- only filter gwt.xml module descriptors --> | |
<include>**/*.gwt.xml</include> | |
</includes> | |
</resource> | |
</resources> | |
<plugins> | |
<plugin> | |
<groupId>org.apache.maven.plugins</groupId> | |
<artifactId>maven-resources-plugin</artifactId> | |
<version>3.0.2</version> | |
<configuration> | |
<encoding>UTF-8</encoding> | |
<!-- Define a custom delimiter for property replacement in the module.gwt.xml file --> | |
<delimiters><!--{*}--></delimiters> | |
</configuration> | |
</plugin> | |
</plugins> | |
</build> | |
</profile> |
Hey mate, thank you for sharing! It worked great here.
Just a small correction at line 34: <delimiters><delimiter><!--{*}--></delimiter></delimiters>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I run it with
mvn clean install -Pfast-build
Optional handy parameters and some can speed a compile too.