Bug 1314 - Fix mvn 'clean' to actually clean up auto generated code. 43/8743/1
authorDevin Avery <devin.avery@brocade.com>
Mon, 7 Jul 2014 18:18:20 +0000 (14:18 -0400)
committerDevin Avery <devin.avery@brocade.com>
Mon, 7 Jul 2014 18:19:40 +0000 (14:19 -0400)
Fixed the maven clean to actually clean up and delete auto generated code.

Change-Id: I249601ca8b3360dec077922bce696ca63b4dde6e
Signed-off-by: Devin Avery <devin.avery@brocade.com>
main/archetypes/archetype-md-sal-app-simple/src/main/resources/archetype-resources/pom.xml

index 407d70eae3d5e83cd55647027a68360890ec7eee..bde33c8193672a6cdd75d4cc4ff8fbf9609199f1 100644 (file)
             <target>${java.version.target}</target>
           </configuration>
         </plugin>
+        <!--  tells eclipse to import these folders into the package explorer as "source" folders
+              which allows eclipse to resolve the classes correctly during an eclipse build -->
         <plugin>
           <groupId>org.codehaus.mojo</groupId>
           <artifactId>build-helper-maven-plugin</artifactId>
             </execution>
           </executions>
         </plugin>
+        <!--  cleans up auto generated code  -->
+        <plugin>
+          <artifactId>maven-clean-plugin</artifactId>
+          <configuration>
+            <filesets>
+              <fileset>
+                <directory>${jmxGeneratorPath}</directory>
+                <includes>
+                  <include>**</include>
+                </includes>
+              </fileset>
+              <fileset>
+                <directory>${salGeneratorPath}</directory>
+                <includes>
+                  <include>**</include>
+                </includes>
+              </fileset>
+            </filesets>
+          </configuration>
+        </plugin>
 
         <!-- Ignore/Execute plugin execution -->
         <plugin>