Resolving: MNG-1056...Added code to reconstruct the remote artifact repository list after the project has had profiles applied. This was already done for plugin repositories. Also, added null protection to DefaultLog per Chris Berry's suggestion.

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@295111 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
John Dennis Casey 2005-10-05 20:43:06 +00:00
parent d3304a8501
commit c66610a6e4
2 changed files with 24 additions and 10 deletions

View File

@ -35,12 +35,24 @@ public class DefaultLog
public void debug( CharSequence content )
{
logger.debug( content.toString() );
logger.debug( toString( content ) );
}
private String toString( CharSequence content )
{
if ( content == null )
{
return "";
}
else
{
return content.toString();
}
}
public void debug( CharSequence content, Throwable error )
{
logger.debug( content.toString(), error );
logger.debug( toString( content ), error );
}
public void debug( Throwable error )
@ -50,12 +62,12 @@ public class DefaultLog
public void info( CharSequence content )
{
logger.info( content.toString() );
logger.info( toString( content ) );
}
public void info( CharSequence content, Throwable error )
{
logger.info( content.toString(), error );
logger.info( toString( content ), error );
}
public void info( Throwable error )
@ -65,12 +77,12 @@ public class DefaultLog
public void warn( CharSequence content )
{
logger.warn( content.toString() );
logger.warn( toString( content ) );
}
public void warn( CharSequence content, Throwable error )
{
logger.warn( content.toString(), error );
logger.warn( toString( content ), error );
}
public void warn( Throwable error )
@ -80,12 +92,12 @@ public class DefaultLog
public void error( CharSequence content )
{
logger.error( content.toString() );
logger.error( toString( content ) );
}
public void error( CharSequence content, Throwable error )
{
logger.error( content.toString(), error );
logger.error( toString( content ), error );
}
public void error( Throwable error )

View File

@ -676,8 +676,10 @@ public class DefaultMavenProjectBuilder
"\'.\n\n Reason(s):\n" + validationResult.render( " " ) );
}
project.setRemoteArtifactRepositories( remoteRepositories );
project.setRemoteArtifactRepositories( ProjectUtils.buildArtifactRepositories( model.getRepositories(),
artifactRepositoryFactory,
container ) );
// TODO: these aren't taking active project artifacts into consideration in the reactor
project.setPluginArtifacts( createPluginArtifacts( project.getBuildPlugins() ) );
project.setReportArtifacts( createReportArtifacts( project.getReportPlugins() ) );