Author: ningjiang
Date: Thu Dec 20 07:06:10 2012
New Revision: 1424349

URL: http://svn.apache.org/viewvc?rev=1424349&view=rev
Log:
CAMEL-5898 update the camel-archetype-groovy with latest groovy DSL support

Modified:
    
camel/trunk/tooling/archetypes/camel-archetype-groovy/src/main/resources/archetype-resources/pom.xml
    
camel/trunk/tooling/archetypes/camel-archetype-groovy/src/main/resources/archetype-resources/src/main/groovy/MyRouteBuilder.groovy

Modified: 
camel/trunk/tooling/archetypes/camel-archetype-groovy/src/main/resources/archetype-resources/pom.xml
URL: 
http://svn.apache.org/viewvc/camel/trunk/tooling/archetypes/camel-archetype-groovy/src/main/resources/archetype-resources/pom.xml?rev=1424349&r1=1424348&r2=1424349&view=diff
==============================================================================
--- 
camel/trunk/tooling/archetypes/camel-archetype-groovy/src/main/resources/archetype-resources/pom.xml
 (original)
+++ 
camel/trunk/tooling/archetypes/camel-archetype-groovy/src/main/resources/archetype-resources/pom.xml
 Thu Dec 20 07:06:10 2012
@@ -84,41 +84,45 @@
                <plugins>
                        <plugin>
                                <groupId>org.apache.maven.plugins</groupId>
+                               <artifactId>maven-resources-plugin</artifactId>
+                               
<version>${maven-resources-plugin-version}</version>
+                               <configuration>
+                                       <encoding>UTF-8</encoding>
+                               </configuration>
+                       </plugin>
+                       <plugin>
                                <artifactId>maven-compiler-plugin</artifactId>
                                
<version>${maven-compiler-plugin-version}</version>
                                <configuration>
                                        <source>1.6</source>
-                                       <target>1.6</target>
+                                       <target>1.6</target>                    
          
+                                       
<compilerId>groovy-eclipse-compiler</compilerId>
+                                   <!-- set verbose to be true if you want 
lots of uninteresting messages -->
+                                   <!-- <verbose>true</verbose> -->
                                </configuration>
+                               <dependencies>
+                                   <dependency>
+                                          
<groupId>org.codehaus.groovy</groupId>
+                                          
<artifactId>groovy-eclipse-compiler</artifactId>
+                                          <version>2.7.0-01</version>
+                                   </dependency>
+                               </dependencies>
                        </plugin>
                        <plugin>
                                <groupId>org.apache.maven.plugins</groupId>
-                               <artifactId>maven-resources-plugin</artifactId>
-                               
<version>${maven-resources-plugin-version}</version>
+                               <artifactId>maven-eclipse-plugin</artifactId>
+                               
<version>${maven-eclipse-plugin-version}</version>
                                <configuration>
-                                       <encoding>UTF-8</encoding>
+                                       <additionalProjectnatures>
+                                               
<projectnature>org.eclipse.jdt.groovy.core.groovyNature</projectnature>
+                                       </additionalProjectnatures>
+                                       <classpathContainers>
+                                               
<classpathContainer>org.eclipse.jdt.launching.JRE_CONTAINER</classpathContainer>
+                                               
<classpathContainer>GROOVY_DSL_SUPPORT</classpathContainer>
+                                       </classpathContainers>              
                                </configuration>
-                       </plugin>
+                       </plugin>         
 
-                       <!-- to compile groovy -->
-                       <plugin>
-                               <groupId>org.codehaus.gmaven</groupId>
-                               <artifactId>gmaven-plugin</artifactId>
-                               <version>${gmaven-plugin-version}</version>
-                               <configuration>
-                                       
<providerSelection>1.8</providerSelection>
-                               </configuration>
-                               <executions>
-                                       <execution>
-                                               <goals>
-                                                       
<goal>generateStubs</goal>
-                                                       <goal>compile</goal>
-                                                       
<goal>generateTestStubs</goal>
-                                                       <goal>testCompile</goal>
-                                               </goals>
-                                       </execution>
-                               </executions>
-                       </plugin>
 
                        <!-- Allows the example to be run via 'mvn compile 
exec:java' -->
                        <plugin>

Modified: 
camel/trunk/tooling/archetypes/camel-archetype-groovy/src/main/resources/archetype-resources/src/main/groovy/MyRouteBuilder.groovy
URL: 
http://svn.apache.org/viewvc/camel/trunk/tooling/archetypes/camel-archetype-groovy/src/main/resources/archetype-resources/src/main/groovy/MyRouteBuilder.groovy?rev=1424349&r1=1424348&r2=1424349&view=diff
==============================================================================
--- 
camel/trunk/tooling/archetypes/camel-archetype-groovy/src/main/resources/archetype-resources/src/main/groovy/MyRouteBuilder.groovy
 (original)
+++ 
camel/trunk/tooling/archetypes/camel-archetype-groovy/src/main/resources/archetype-resources/src/main/groovy/MyRouteBuilder.groovy
 Thu Dec 20 07:06:10 2012
@@ -28,8 +28,7 @@ class MyRouteBuilder extends RouteBuilde
      */
     void configure() {
         from("jetty:http://0.0.0.0:8080";)
-          .transform()
-            .groovy("'Today is ' + new Date()")
+          .transform { 'Today is ' + new Date() }
     }
 
 }


Reply via email to