Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to deploy GWT application with pretty compiled HTML using google plugin for Eclipse

I use google plugin for eclipse to deploy my GWT application, it works good until now, the deploy action first compiles my GWT project with "obfuscated" output style, now i want it change to "Pretty" because i have to debug the client side on the fly, i just can't see the obfuscated stack.

Thanks.

like image 787
Mike Avatar asked Oct 05 '12 12:10

Mike


People also ask

How to install GWT Plugin in Eclipse?

Install from the Eclipse MarketplaceGo to the Eclipse Market Place and search for GWT . First goto the Eclipse Market Place. Then Search for GWT and install the features. Then Choose all the features you want to install.


2 Answers

Compiler level is part of the GWT compiler options :

-style Script output style: OBF[USCATED], PRETTY, or DETAILED (defaults to OBF)

If you're using Ant :

modify your build.xml file :

<arg value="-style"/>
<arg value="pretty"/>

If you're using Maven :

modify your pom.xml file :

<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>gwt-maven-plugin</artifactId>
<version>2.4.0</version>
<executions>
    <execution>
        <goals>
            <goal>compile</goal>
        </goals>
        </execution>
</executions>
<configuration>
    <style>PRETTY</style>
    <!-- OTHER STUFF -->
</configuration>
</plugin>
like image 168
Jean-Michel Garcia Avatar answered Sep 28 '22 23:09

Jean-Michel Garcia


The solution is simple, first open "GWT compile" dialog, select Detailed or Pretty, click apply, close the dialog, then it will be deployed with Detailed or Pretty style.

like image 31
Mike Avatar answered Sep 28 '22 23:09

Mike