]> source.dussan.org Git - gwtquery.git/commitdiff
Use GWT 2.8.0 and net.ltgt maven plugin in archetype master
authorManolo Carrasco <manolo@vaadin.com>
Mon, 24 Apr 2017 20:45:18 +0000 (22:45 +0200)
committerManolo Carrasco <manolo@vaadin.com>
Mon, 24 Apr 2017 20:52:23 +0000 (22:52 +0200)
archetype/pom.xml
archetype/src/main/resources/archetype-resources/pom.xml
archetype/src/main/resources/archetype-resources/src/main/java/__artifactId__/__projectName__.gwt.xml [deleted file]
archetype/src/main/resources/archetype-resources/src/main/java/__artifactId__/client/__projectName__.java [deleted file]
archetype/src/main/resources/archetype-resources/src/main/java/__artifactId__/public/__projectName__.html [deleted file]
archetype/src/main/resources/archetype-resources/src/main/java/__projectName__.gwt.xml [new file with mode: 0644]
archetype/src/main/resources/archetype-resources/src/main/java/client/__projectName__.java [new file with mode: 0644]
archetype/src/main/resources/archetype-resources/src/main/java/public/__projectName__.html [new file with mode: 0644]
archetype/src/main/resources/archetype-resources/src/test/java/__artifactId__/client/__projectName__Test.java

index 4d4b8cdbe812bb3ed5ab757e9fc194e65f35250d..9255f1897ca6c93a6ed4a06871fedb56cd0dcb57 100644 (file)
@@ -14,7 +14,7 @@
     <version>3</version>
   </parent>
 
-  <description>This archetype generates a GWT-2.6.1 project with all set to use GwtQuery and its plugins.</description>
+  <description>This archetype generates a GWT project with all set to use GwtQuery and its plugins.</description>
 
   <scm>
     <connection>scm:git:https://code.google.com/p/gwtquery/</connection>
index d92dd68bb2f942c2d5357434094a5d496ade20f3..1557e72e3c3ff99083710eaf04009e50b782da50 100644 (file)
 
     <properties>
       <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
-      <maven.compiler.source>1.7</maven.compiler.source>
-      <maven.compiler.target>1.7</maven.compiler.target>
-      <gQueryVersion>1.4.3-SNAPSHOT</gQueryVersion>
-      <gwtversion>2.6.1</gwtversion>
-      <gwtmaven>2.6.1</gwtmaven>
+      <maven.compiler.source>1.8</maven.compiler.source>
+      <maven.compiler.target>1.8</maven.compiler.target>
+      <gQueryVersion>1.5-SNAPSHOT</gQueryVersion>
+      <gwtversion>2.8.0</gwtversion>
+      <gwtmaven>2.8.0</gwtmaven>
     </properties>
 
     <repositories>
     <issueManagement>
     </issueManagement>
 
+    <dependencyManagement>
+      <dependencies>
+        <dependency>
+          <groupId>com.google.gwt</groupId>
+          <artifactId>gwt</artifactId>
+          <version>${gwtversion}</version>
+          <type>pom</type>
+          <scope>import</scope>
+        </dependency>
+      </dependencies>
+    </dependencyManagement>
+
     <dependencies>
         <dependency>
             <groupId>junit</groupId>
             <artifactId>junit</artifactId>
-            <version>3.8.1</version>
+            <version>4.11</version>
             <scope>test</scope>
         </dependency>
         <dependency>
             <groupId>com.google.gwt</groupId>
             <artifactId>gwt-user</artifactId>
-            <version>${gwtversion}</version>
             <scope>provided</scope>
         </dependency>
         <dependency>
             <groupId>com.google.gwt</groupId>
             <artifactId>gwt-dev</artifactId>
-            <version>${gwtversion}</version>
             <scope>provided</scope>
         </dependency>
         <dependency>
             <groupId>com.google.gwt</groupId>
             <artifactId>gwt-servlet</artifactId>
-            <version>${gwtversion}</version>
             <scope>runtime</scope>
         </dependency>
         <dependency>
             <version>${gQueryVersion}</version>
             <scope>provided</scope>
         </dependency>
-        <!-- GWT 2.3.0 depends on these -->
-        <dependency>
-            <groupId>javax.validation</groupId>
-            <artifactId>validation-api</artifactId>
-            <version>1.0.0.GA</version>
-        </dependency>
-        <dependency>
-            <groupId>javax.validation</groupId>
-            <artifactId>validation-api</artifactId>
-            <version>1.0.0.GA</version>
-            <classifier>sources</classifier>
-        </dependency>
     </dependencies>
     <build>
         <plugins>
             <plugin>
-              <groupId>org.apache.maven.plugins</groupId>
-              <artifactId>maven-compiler-plugin</artifactId>
-              <version>2.1</version>
+              <groupId>net.ltgt.gwt.maven</groupId>
+              <artifactId>gwt-maven-plugin</artifactId>
+              <version>1.0-rc-6</version>
+              <executions>
+                <execution>
+                  <goals>
+                    <goal>import-sources</goal>
+                    <goal>compile</goal>
+                    <goal>import-test-sources</goal>
+                    <goal>test</goal>
+                  </goals>
+                </execution>
+              </executions>
               <configuration>
-                <source>1.6</source>
-                <target>1.6</target>
+                <moduleName>${package}.${projectName}</moduleName>
+                <moduleShortName>${projectName}</moduleShortName>
+                <failOnError>true</failOnError>
+                <sourceLevel>1.8</sourceLevel>
+                <compilerArgs>
+                  <arg>-compileReport</arg>
+                  <arg>-XcompilerMetrics</arg>
+                </compilerArgs>
+                <warDir>${project.build.directory}/${project.build.finalName}</warDir>
+                <classpathScope>compile+runtime</classpathScope>
+                <startupUrls>
+                  <startupUrl>${projectName}/${projectName}.html</startupUrl>
+                </startupUrls>
               </configuration>
             </plugin>
+
             <plugin>
-                <groupId>org.codehaus.mojo</groupId>
-                <artifactId>gwt-maven-plugin</artifactId>
-                <version>${gwtmaven}</version>
-                <configuration>
-                    <logLevel>${gwt.loglevel}</logLevel>
-                    <style>${gwt.outputstyle}</style>
-                    <gwtVersion>${gwtversion}</gwtVersion>
-                    <compileReport>true</compileReport>
-                    <runTarget>${projectName}/${projectName}.html</runTarget>
-                    <hostedWebApp>${project.build.directory}/${project.build.finalName}</hostedWebApp>
-                </configuration>
-                <executions>
-                    <execution>
-                        <phase>prepare-package</phase>
-                        <goals>
-                            <goal>compile</goal>
-                        </goals>
-                    </execution>
-                </executions>
-            </plugin>
-            <plugin>
-               <artifactId>maven-surefire-plugin</artifactId>
-               <version>2.8.1</version>
-               <configuration>
-                 <additionalClasspathElements>
-                   <additionalClasspathElement>\${project.build.sourceDirectory}</additionalClasspathElement>
-                   <additionalClasspathElement>\${project.build.testSourceDirectory}</additionalClasspathElement>
-                 </additionalClasspathElements>
-                 <useManifestOnlyJar>false</useManifestOnlyJar>
-                 <forkMode>always</forkMode>
-                 <systemProperties>
-                   <property>
-                     <name>gwt.args</name>
-                     <value>-out target/gwt-tests</value>
-                   </property>
-                   <property>
-                     <!-- Setting this to true (default) causes a exception first time test are run Gwt issue_6443 -->
-                     <name>gwt.persistentunitcache</name>
-                     <value>false</value>
-                   </property>
-                 </systemProperties>
-               </configuration>
-            </plugin>
-            <plugin>
-              <groupId>org.apache.maven.plugins</groupId>
-              <artifactId>maven-eclipse-plugin</artifactId>
-              <version>2.7</version>
+              <artifactId>maven-surefire-plugin</artifactId>
+              <version>2.17</version>
               <configuration>
-                 <downloadSources>true</downloadSources>
-                 <downloadJavadocs>false</downloadJavadocs>
-                 <additionalBuildcommands>
-                   <buildcommand>com.google.gwt.eclipse.core.gwtProjectValidator</buildcommand>
-                   <buildcommand>org.eclipse.wst.common.modulecore.ComponentStructuralBuilder</buildcommand>
-                   <buildcommand>org.eclipse.jdt.core.javabuilder</buildcommand>
-                   <buildcommand>org.eclipse.wst.common.modulecore.ComponentStructuralBuilderDependencyResolver</buildcommand>
-                 </additionalBuildcommands>
-                 <additionalProjectnatures>
-                   <projectnature>com.google.gwt.eclipse.core.gwtNature</projectnature>
-                   <projectnature>org.eclipse.jdt.core.javanature</projectnature>
-                   <projectnature>org.eclipse.wst.common.modulecore.ModuleCoreNature</projectnature>
-                 </additionalProjectnatures>
-                 <classpathContainers>
-                   <classpathContainer>com.google.gwt.eclipse.core.GWT_CONTAINER</classpathContainer>
-                   <classpathContainer>org.eclipse.jdt.launching.JRE_CONTAINER</classpathContainer>
-                   <classpathContainer>org.eclipse.jdt.junit.JUNIT_CONTAINER/3</classpathContainer>
-                </classpathContainers>
+                <skip>true</skip>
               </configuration>
             </plugin>
-            <!-- GWT plugin does not copy the webapp folder in hosted mode -->
             <plugin>
               <artifactId>maven-resources-plugin</artifactId>
               <version>2.5</version>
diff --git a/archetype/src/main/resources/archetype-resources/src/main/java/__artifactId__/__projectName__.gwt.xml b/archetype/src/main/resources/archetype-resources/src/main/java/__artifactId__/__projectName__.gwt.xml
deleted file mode 100644 (file)
index 13e1d57..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-#set( $symbol_pound = '#' )
-#set( $symbol_dollar = '$' )
-#set( $symbol_escape = '\' )
-<module rename-to='${projectName}'>
-    <inherits name='com.google.gwt.query.Query'/>
-    <entry-point class='${package}.${artifactId}.client.${projectName}'/>
-</module>
-
diff --git a/archetype/src/main/resources/archetype-resources/src/main/java/__artifactId__/client/__projectName__.java b/archetype/src/main/resources/archetype-resources/src/main/java/__artifactId__/client/__projectName__.java
deleted file mode 100644 (file)
index d5c178e..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-#set( $symbol_pound = '#' )
-#set( $symbol_dollar = '$' )
-#set( $symbol_escape = '\' )
-package ${package}.${artifactId}.client;
-import com.google.gwt.dom.client.Element;
-import com.google.gwt.query.client.Function;
-import static com.google.gwt.query.client.GQuery.*;
-
-
-import com.google.gwt.core.client.EntryPoint;
-
-/**
- * Example code for a GwtQuery application
- */
-public class ${projectName} implements EntryPoint {
-
-  public void onModuleLoad() {
-
-    ${symbol_dollar}("div")
-    .hover(new Function() {
-      public void f(Element e) {
-        ${symbol_dollar}(e).css("color", "blue").stop(true, true).animate("fontSize: '+=10px'");
-      }
-    }, new Function() {
-      public void f(Element e) {
-        ${symbol_dollar}(e).css("color", "").stop(true, true).animate("fontSize: '-=10px'");
-      }
-    });
-  }
-
-}
diff --git a/archetype/src/main/resources/archetype-resources/src/main/java/__artifactId__/public/__projectName__.html b/archetype/src/main/resources/archetype-resources/src/main/java/__artifactId__/public/__projectName__.html
deleted file mode 100644 (file)
index 6caf14b..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-#set( $symbol_pound = '#' )
-#set( $symbol_dollar = '$' )
-#set( $symbol_escape = '\' )
-<!doctype html>
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
-<title>GwtQuery: ${projectName} plugin example</title>
-<style type="text/css">
-</style>
-    <script language="javascript" src="${projectName}.nocache.js"></script>
-</head>
-  <body>
-    <div>Hello world</div>
-  </body>
-</html>
diff --git a/archetype/src/main/resources/archetype-resources/src/main/java/__projectName__.gwt.xml b/archetype/src/main/resources/archetype-resources/src/main/java/__projectName__.gwt.xml
new file mode 100644 (file)
index 0000000..063e7a9
--- /dev/null
@@ -0,0 +1,8 @@
+#set( $symbol_pound = '#' )
+#set( $symbol_dollar = '$' )
+#set( $symbol_escape = '\' )
+<module rename-to='${projectName}'>
+    <inherits name='com.google.gwt.query.Query'/>
+    <entry-point class='${package}.client.${projectName}'/>
+</module>
+
diff --git a/archetype/src/main/resources/archetype-resources/src/main/java/client/__projectName__.java b/archetype/src/main/resources/archetype-resources/src/main/java/client/__projectName__.java
new file mode 100644 (file)
index 0000000..32be211
--- /dev/null
@@ -0,0 +1,31 @@
+#set( $symbol_pound = '#' )
+#set( $symbol_dollar = '$' )
+#set( $symbol_escape = '\' )
+package ${package}.client;
+import com.google.gwt.dom.client.Element;
+import com.google.gwt.query.client.Function;
+import static com.google.gwt.query.client.GQuery.*;
+
+
+import com.google.gwt.core.client.EntryPoint;
+
+/**
+ * Example code for a GwtQuery application
+ */
+public class ${projectName} implements EntryPoint {
+
+  public void onModuleLoad() {
+
+    ${symbol_dollar}("div")
+    .hover(new Function() {
+      public void f(Element e) {
+        ${symbol_dollar}(e).css("color", "blue").stop(true, true).animate("fontSize: '+=10px'");
+      }
+    }, new Function() {
+      public void f(Element e) {
+        ${symbol_dollar}(e).css("color", "").stop(true, true).animate("fontSize: '-=10px'");
+      }
+    });
+  }
+
+}
diff --git a/archetype/src/main/resources/archetype-resources/src/main/java/public/__projectName__.html b/archetype/src/main/resources/archetype-resources/src/main/java/public/__projectName__.html
new file mode 100644 (file)
index 0000000..6caf14b
--- /dev/null
@@ -0,0 +1,16 @@
+#set( $symbol_pound = '#' )
+#set( $symbol_dollar = '$' )
+#set( $symbol_escape = '\' )
+<!doctype html>
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
+<title>GwtQuery: ${projectName} plugin example</title>
+<style type="text/css">
+</style>
+    <script language="javascript" src="${projectName}.nocache.js"></script>
+</head>
+  <body>
+    <div>Hello world</div>
+  </body>
+</html>
index e007a0a65e1ea270f1047f29354742dc57a1ba9b..a2d64b9b71ef7c1847cc2c9e651d37378dcfd9ad 100644 (file)
@@ -1,7 +1,7 @@
 #set( $symbol_pound = '#' )
 #set( $symbol_dollar = '$' )
 #set( $symbol_escape = '\' )
-package ${package}.${artifactId}.client;
+package ${package}.client;
 
 import static com.google.gwt.query.client.GQuery.*;
 import com.google.gwt.junit.client.GWTTestCase;
@@ -15,7 +15,7 @@ import com.google.gwt.user.client.Timer;
 public class ${projectName}Test extends GWTTestCase {
 
   public String getModuleName() {
-    return "${package}.${artifactId}.${projectName}";
+    return "${package}.${projectName}";
   }
 
   private double fontSize(GQuery g) {