[MNG-1493] Modifying to allow <module> to specify a full path, including alternate pom file, rather than just a directory wherein a normal 'pom.xml' is expected to reside. This works more like <relativePath> has worked for awhile now.

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@618780 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
John Dennis Casey 2008-02-05 21:27:53 +00:00
parent ad27233c7c
commit 04ad40121c
1 changed files with 13 additions and 14 deletions

View File

@ -350,15 +350,21 @@ public class DefaultMaven
continue;
}
File moduleFile;
if ( usingReleasePom )
File moduleFile = new File( basedir, name );
if ( !moduleFile.exists() )
{
moduleFile = new File( basedir, name + "/" + Maven.RELEASE_POMv4 );
throw new MissingModuleException( name, moduleFile, file );
}
else
else if ( moduleFile.isDirectory() )
{
moduleFile = new File( basedir, name + "/" + Maven.POMv4 );
if ( usingReleasePom )
{
moduleFile = new File( basedir, name + "/" + Maven.RELEASE_POMv4 );
}
else
{
moduleFile = new File( basedir, name + "/" + Maven.POMv4 );
}
}
if ( Os.isFamily( Os.FAMILY_WINDOWS ) )
@ -379,14 +385,7 @@ public class DefaultMaven
moduleFile = new File( moduleFile.toURI().normalize() );
}
if ( !moduleFile.exists() )
{
throw new MissingModuleException( name, moduleFile, file );
}
else
{
moduleFiles.add( moduleFile );
}
moduleFiles.add( moduleFile );
}
List collectedProjects = collectProjects( moduleFiles, localRepository, recursive,