mirror of https://github.com/apache/maven.git
o Fixed NPE in LegacyArtifactDiscoverer when the resulting Artifact from the buildArtifact() method is null (was an errant debug statement)
o Removed requirement and attempt at copying wagon-http-lightweight when ./install.sh runs. o Cleaned up the output from ./repoclean.sh to remove a couple debug lines o Fixed components.xml to comply with the new component refactorings (simplified RepositoryCleaner using two new processing phases: DiscoveryPhase and RewritePhase, with NO common interface) We should be ready to process mixed bags of m1 and m2 poms in the same source repo now! git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@169330 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
637c0f815b
commit
17c195e01d
|
@ -65,8 +65,6 @@ ret=$?; if [ $ret != 0 ]; then exit $ret; fi
|
||||||
|
|
||||||
cp -f $2/org/apache/maven/wagon/wagon-file/1.0-alpha-2/wagon-file-1.0-alpha-2.jar $1/lib
|
cp -f $2/org/apache/maven/wagon/wagon-file/1.0-alpha-2/wagon-file-1.0-alpha-2.jar $1/lib
|
||||||
|
|
||||||
cp -f $2/org/apache/maven/wagon/wagon-http-lightweight/1.0-alpha-2/wagon-http-lightweight-1.0-alpha-2.jar $1/lib
|
|
||||||
|
|
||||||
echo "Copying startup script, and changing its permissions to '+x'..."
|
echo "Copying startup script, and changing its permissions to '+x'..."
|
||||||
echo ""
|
echo ""
|
||||||
|
|
||||||
|
|
|
@ -2,19 +2,14 @@
|
||||||
|
|
||||||
mypath=`which $0`
|
mypath=`which $0`
|
||||||
|
|
||||||
echo "mypath: $mypath"
|
|
||||||
|
|
||||||
mydir=`pwd`
|
mydir=`pwd`
|
||||||
|
|
||||||
if [ "" != "$mypath" ]; then
|
if [ "" != "$mypath" ]; then
|
||||||
|
|
||||||
echo "Setting mydir based on mypath..."
|
|
||||||
mydir=`dirname $mypath`
|
mydir=`dirname $mypath`
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "mydir: $mydir"
|
|
||||||
|
|
||||||
CP=$mydir/lib/repoclean-1.0-SNAPSHOT.jar
|
CP=$mydir/lib/repoclean-1.0-SNAPSHOT.jar
|
||||||
|
|
||||||
for lib in `ls -1 $mydir/lib | grep -v 'repoclean'`
|
for lib in `ls -1 $mydir/lib | grep -v 'repoclean'`
|
||||||
|
@ -46,4 +41,4 @@ if [ -z "$JAVA_HOME" ]; then
|
||||||
JAVA_HOME=/usr/local/java
|
JAVA_HOME=/usr/local/java
|
||||||
fi
|
fi
|
||||||
|
|
||||||
nice -n 19 $JAVA_HOME/bin/java -Xmx128M -Xms64M -Xincgc $JAVA_OPTS -classpath ${CP} org.apache.maven.tools.repoclean.Main $* | tee repoclean-log.txt
|
nice -n 19 $JAVA_HOME/bin/java -Xmx128M -Xms64M -Xincgc $JAVA_OPTS -classpath ${CP} org.apache.maven.tools.repoclean.Main $*
|
||||||
|
|
|
@ -18,6 +18,7 @@ import org.apache.maven.artifact.Artifact;
|
||||||
import org.apache.maven.artifact.factory.ArtifactFactory;
|
import org.apache.maven.artifact.factory.ArtifactFactory;
|
||||||
import org.apache.maven.tools.repoclean.report.PathLister;
|
import org.apache.maven.tools.repoclean.report.PathLister;
|
||||||
import org.apache.maven.tools.repoclean.report.Reporter;
|
import org.apache.maven.tools.repoclean.report.Reporter;
|
||||||
|
import org.codehaus.plexus.util.StringUtils;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
@ -293,18 +294,23 @@ public class LegacyArtifactDiscoverer
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
result = artifactFactory.createArtifact( groupId, artifactId, version, Artifact.SCOPE_RUNTIME, type );
|
if ( StringUtils.isNotEmpty( groupId ) && StringUtils.isNotEmpty( artifactId )
|
||||||
|
&& StringUtils.isNotEmpty( version ) && StringUtils.isNotEmpty( type ) )
|
||||||
|
{
|
||||||
|
result = artifactFactory
|
||||||
|
.createArtifact( groupId, artifactId, version, Artifact.SCOPE_RUNTIME, type );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
getLogger().debug(
|
// getLogger().debug(
|
||||||
"Resulting artifact is: " + result.getId() + " and has classifier of: "
|
// "Resulting artifact is: " + result + " and has classifier of: "
|
||||||
+ result.getClassifier() + "\n\n" );
|
// + result.getClassifier() + "\n\n" );
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
catch ( RuntimeException e )
|
catch ( RuntimeException e )
|
||||||
{
|
{
|
||||||
getLogger().error( "While parsing artifact path: \'" + path + "\'...\n\n", e );
|
getLogger().error( "While parsing artifact path: \'" + path + "\'...", e );
|
||||||
|
|
||||||
throw e;
|
throw e;
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,6 +3,38 @@
|
||||||
<component>
|
<component>
|
||||||
<role>org.apache.maven.tools.repoclean.RepositoryCleaner</role>
|
<role>org.apache.maven.tools.repoclean.RepositoryCleaner</role>
|
||||||
<implementation>org.apache.maven.tools.repoclean.RepositoryCleaner</implementation>
|
<implementation>org.apache.maven.tools.repoclean.RepositoryCleaner</implementation>
|
||||||
|
<requirements>
|
||||||
|
<requirement>
|
||||||
|
<role>org.apache.maven.tools.repoclean.index.ArtifactIndexer</role>
|
||||||
|
</requirement>
|
||||||
|
<requirement>
|
||||||
|
<role>org.codehaus.plexus.mailsender.MailSender</role>
|
||||||
|
</requirement>
|
||||||
|
<requirement>
|
||||||
|
<role>org.apache.maven.tools.repoclean.phase.DiscoveryPhase</role>
|
||||||
|
</requirement>
|
||||||
|
<requirement>
|
||||||
|
<role>org.apache.maven.tools.repoclean.phase.RewritePhase</role>
|
||||||
|
</requirement>
|
||||||
|
</requirements>
|
||||||
|
</component>
|
||||||
|
<!--
|
||||||
|
|
|
||||||
|
|
|
||||||
|
|
|
||||||
|
-->
|
||||||
|
<component>
|
||||||
|
<role>org.apache.maven.tools.repoclean.phase.DiscoveryPhase</role>
|
||||||
|
<implementation>org.apache.maven.tools.repoclean.phase.DiscoveryPhase</implementation>
|
||||||
|
</component>
|
||||||
|
<!--
|
||||||
|
|
|
||||||
|
|
|
||||||
|
|
|
||||||
|
-->
|
||||||
|
<component>
|
||||||
|
<role>org.apache.maven.tools.repoclean.phase.RewritePhase</role>
|
||||||
|
<implementation>org.apache.maven.tools.repoclean.phase.RewritePhase</implementation>
|
||||||
<requirements>
|
<requirements>
|
||||||
<requirement>
|
<requirement>
|
||||||
<role>org.apache.maven.artifact.repository.layout.ArtifactRepositoryLayout</role>
|
<role>org.apache.maven.artifact.repository.layout.ArtifactRepositoryLayout</role>
|
||||||
|
@ -12,12 +44,6 @@
|
||||||
<requirement>
|
<requirement>
|
||||||
<role>org.apache.maven.tools.repoclean.digest.DigestVerifier</role>
|
<role>org.apache.maven.tools.repoclean.digest.DigestVerifier</role>
|
||||||
</requirement>
|
</requirement>
|
||||||
<requirement>
|
|
||||||
<role>org.apache.maven.tools.repoclean.index.ArtifactIndexer</role>
|
|
||||||
</requirement>
|
|
||||||
<requirement>
|
|
||||||
<role>org.codehaus.plexus.mailsender.MailSender</role>
|
|
||||||
</requirement>
|
|
||||||
</requirements>
|
</requirements>
|
||||||
</component>
|
</component>
|
||||||
<!--
|
<!--
|
||||||
|
|
Loading…
Reference in New Issue