From b2a4a02c00b70a0265251bd57fc772bebafba434 Mon Sep 17 00:00:00 2001 From: Joakim Erdfelt Date: Fri, 11 May 2007 22:25:12 +0000 Subject: [MRM-336]: Repository Admin - "Index Repository" appears to not do anything. git-svn-id: https://svn.apache.org/repos/asf/maven/archiva/trunk@537304 13f79535-47bb-0310-9956-ffa450edef68 --- .../org/apache/maven/archiva/cli/ArchivaCli.java | 21 +-------------------- 1 file changed, 1 insertion(+), 20 deletions(-) (limited to 'archiva-cli') diff --git a/archiva-cli/src/main/java/org/apache/maven/archiva/cli/ArchivaCli.java b/archiva-cli/src/main/java/org/apache/maven/archiva/cli/ArchivaCli.java index 3f5b03872..a9824e8ac 100644 --- a/archiva-cli/src/main/java/org/apache/maven/archiva/cli/ArchivaCli.java +++ b/archiva-cli/src/main/java/org/apache/maven/archiva/cli/ArchivaCli.java @@ -23,7 +23,6 @@ import org.apache.commons.cli.CommandLine; import org.apache.commons.cli.Option; import org.apache.commons.cli.Options; import org.apache.commons.lang.StringUtils; -import org.apache.maven.archiva.common.utils.DateUtil; import org.apache.maven.archiva.configuration.ArchivaConfiguration; import org.apache.maven.archiva.consumers.ConsumerException; import org.apache.maven.archiva.consumers.RepositoryContentConsumer; @@ -40,7 +39,6 @@ import org.codehaus.plexus.tools.cli.AbstractCli; import java.io.File; import java.io.FileInputStream; import java.io.IOException; -import java.text.SimpleDateFormat; import java.util.ArrayList; import java.util.Arrays; import java.util.Collection; @@ -187,24 +185,7 @@ public class ArchivaCli RepositoryContentStatistics stats = scanner.scan( repo, knownConsumerList, invalidConsumerList, ignoredContent, RepositoryScanner.FRESH_SCAN ); - SimpleDateFormat df = new SimpleDateFormat(); - System.out.println( "" ); - System.out.println( ".\\ Scan of " + repo.getId() + " \\.__________________________________________" ); - System.out.println( " Repository URL : " + repo.getUrl() ); - System.out.println( " Repository Name : " + repo.getModel().getName() ); - System.out.println( " Repository Layout : " + repo.getModel().getLayoutName() ); - System.out.println( " Consumers : (" + knownConsumerList.size() + " active)" ); - for ( Iterator iter = knownConsumerList.iterator(); iter.hasNext(); ) - { - RepositoryContentConsumer consumer = (RepositoryContentConsumer) iter.next(); - System.out.println( " " + consumer.getId() + " - " + consumer.getDescription() ); - } - System.out.println( " Duration : " + DateUtil.getDuration( stats.getDuration() ) ); - System.out.println( " When Gathered : " + df.format( stats.getWhenGathered() ) ); - System.out.println( " Total File Count : " + stats.getTotalFileCount() ); - long averageMsPerFile = ( stats.getDuration() / stats.getTotalFileCount() ); - System.out.println( " Avg Time Per File : " + DateUtil.getDuration( averageMsPerFile ) ); - System.out.println( "______________________________________________________________" ); + System.out.println( "\n" + stats.toDump( repo ) ); } catch ( RepositoryException e ) { -- cgit v1.2.3