Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
Copyright 2011-2012 The Kuali Foundation Licensed under the Educational Community License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
 package org.kuali.maven.plugins.externals;
 import java.util.List;
 import java.util.Map;
Make sure the aggregate checkout is "self-contained". Make sure the parent versions of the svn:externals modules point back to the correct root pom. Make sure the properties used to figure out which version of the child modules to use, actually match up with the versions declared in the child modules.

 public class ValidatePomsMojo extends AbstractMojo {
 	SVNUtils svnUtils = SVNUtils.getInstance();
 	MojoHelper helper = MojoHelper.getInstance();

Filename pattern used to discover Maven pom's

expression="${externals.pom}" default-value="pom.xml"
 	private String pom;

Directories to ignore when examining the file system for Maven pom's

expression="${externals.ignoreDirectories}" default-value="src,target,.svn,.git"
The Maven project object

 	private MavenProject project;

These mappings connect the svn:externals definitions with a property inside the root pom that controls what version each external is set to

 	private List<Mappingmappings;
 	public void execute() throws MojoExecutionException {
 		// Since this tree is based on the file system directory structure, it should always be a perfect tree
 		// Make sure each GAV is fully populated
 		// Populate a map keyed by the GAV id
 		// Validate that all of the parents are contained in the map
 		int depth = node.getDepth();
 		int size = nodes.size();
 		getLog().info("Validated " + size + " POM's.  Multi-module Maven project depth: " + depth);
 	public String getPom() {
 		return ;
 	public void setPom(String pom) {
 		this. = pom;
 	public void setIgnoreDirectories(String ignoreDirectories) {
 		this. = ignoreDirectories;
		return ;
	public void setProject(MavenProject project) {
		this. = project;
	public List<MappinggetMappings() {
		return ;
	public void setMappings(List<Mappingmappings) {
		this. = mappings;
New to GrepCode? Check out our FAQ X