mirror of https://github.com/apache/maven.git
[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:
parent
ad27233c7c
commit
04ad40121c
|
@ -350,15 +350,21 @@ public class DefaultMaven
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
File moduleFile;
|
File moduleFile = new File( basedir, name );
|
||||||
|
if ( !moduleFile.exists() )
|
||||||
if ( usingReleasePom )
|
|
||||||
{
|
{
|
||||||
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 ) )
|
if ( Os.isFamily( Os.FAMILY_WINDOWS ) )
|
||||||
|
@ -379,14 +385,7 @@ public class DefaultMaven
|
||||||
moduleFile = new File( moduleFile.toURI().normalize() );
|
moduleFile = new File( moduleFile.toURI().normalize() );
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( !moduleFile.exists() )
|
moduleFiles.add( moduleFile );
|
||||||
{
|
|
||||||
throw new MissingModuleException( name, moduleFile, file );
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
moduleFiles.add( moduleFile );
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
List collectedProjects = collectProjects( moduleFiles, localRepository, recursive,
|
List collectedProjects = collectProjects( moduleFiles, localRepository, recursive,
|
||||||
|
|
Loading…
Reference in New Issue