org.apache.maven.index.cli
Class NexusIndexerCli

java.lang.Object
  extended by org.codehaus.plexus.tools.cli.AbstractCli
      extended by org.apache.maven.index.cli.NexusIndexerCli
All Implemented Interfaces:
org.codehaus.plexus.tools.cli.Cli

public class NexusIndexerCli
extends org.codehaus.plexus.tools.cli.AbstractCli

A command line tool that can be used to index local Maven repository.

The following command line options are supported:

When index folder contains previously created index, the tool will use it as a base line and will generate chunks for the incremental updates.

The indexer types could be one of default, min or full. You can also specify list of comma-separated custom index creators. An index creator should be a regular Plexus component, see MinimalArtifactInfoIndexCreator and JarFileContentsIndexCreator.


Field Summary
static char CREATE_FILE_CHECKSUMS
           
static char CREATE_INCREMENTAL_CHUNKS
           
static char INCREMENTAL_CHUNK_KEEP_COUNT
           
static char INDEX
           
static char LEGACY
           
static char NAME
           
static char REPO
           
static char TARGET_DIR
           
static char TYPE
           
static char UNPACK
           
 
Fields inherited from class org.codehaus.plexus.tools.cli.AbstractCli
DEBUG, ERRORS, HELP, QUIET, SET_SYSTEM_PROPERTY, VERSION
 
Constructor Summary
NexusIndexerCli()
           
 
Method Summary
 org.apache.commons.cli.Options buildCliOptions(org.apache.commons.cli.Options options)
           
 void displayHelp()
           
 void displayHelp(String message)
           
 int execute(String[] args)
           
 int execute(String[] arg0, org.codehaus.plexus.classworlds.ClassWorld arg1)
           
 String getPomPropertiesPath()
           
 void invokePlexusComponent(org.apache.commons.cli.CommandLine cli, org.codehaus.plexus.PlexusContainer plexus)
           
static void main(String[] args)
           
 org.apache.commons.cli.CommandLine parse(String[] args)
           
protected  void showError(String message, Exception e, boolean show)
           
protected  int showFatalError(String message, Exception e, boolean show)
           
 
Methods inherited from class org.codehaus.plexus.tools.cli.AbstractCli
buildDefaultCliOptions
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

REPO

public static final char REPO
See Also:
Constant Field Values

INDEX

public static final char INDEX
See Also:
Constant Field Values

NAME

public static final char NAME
See Also:
Constant Field Values

TYPE

public static final char TYPE
See Also:
Constant Field Values

TARGET_DIR

public static final char TARGET_DIR
See Also:
Constant Field Values

CREATE_INCREMENTAL_CHUNKS

public static final char CREATE_INCREMENTAL_CHUNKS
See Also:
Constant Field Values

CREATE_FILE_CHECKSUMS

public static final char CREATE_FILE_CHECKSUMS
See Also:
Constant Field Values

INCREMENTAL_CHUNK_KEEP_COUNT

public static final char INCREMENTAL_CHUNK_KEEP_COUNT
See Also:
Constant Field Values

LEGACY

public static final char LEGACY
See Also:
Constant Field Values

UNPACK

public static final char UNPACK
See Also:
Constant Field Values
Constructor Detail

NexusIndexerCli

public NexusIndexerCli()
Method Detail

main

public static void main(String[] args)
                 throws Exception
Throws:
Exception

execute

public int execute(String[] arg0,
                   org.codehaus.plexus.classworlds.ClassWorld arg1)
Overrides:
execute in class org.codehaus.plexus.tools.cli.AbstractCli

execute

public int execute(String[] args)
Overrides:
execute in class org.codehaus.plexus.tools.cli.AbstractCli

showError

protected void showError(String message,
                         Exception e,
                         boolean show)
Overrides:
showError in class org.codehaus.plexus.tools.cli.AbstractCli

showFatalError

protected int showFatalError(String message,
                             Exception e,
                             boolean show)
Overrides:
showFatalError in class org.codehaus.plexus.tools.cli.AbstractCli

parse

public org.apache.commons.cli.CommandLine parse(String[] args)
                                         throws org.apache.commons.cli.ParseException
Overrides:
parse in class org.codehaus.plexus.tools.cli.AbstractCli
Throws:
org.apache.commons.cli.ParseException

getPomPropertiesPath

public String getPomPropertiesPath()
Specified by:
getPomPropertiesPath in interface org.codehaus.plexus.tools.cli.Cli
Overrides:
getPomPropertiesPath in class org.codehaus.plexus.tools.cli.AbstractCli

buildCliOptions

public org.apache.commons.cli.Options buildCliOptions(org.apache.commons.cli.Options options)
Specified by:
buildCliOptions in interface org.codehaus.plexus.tools.cli.Cli
Specified by:
buildCliOptions in class org.codehaus.plexus.tools.cli.AbstractCli

displayHelp

public void displayHelp()
Overrides:
displayHelp in class org.codehaus.plexus.tools.cli.AbstractCli

displayHelp

public void displayHelp(String message)

invokePlexusComponent

public void invokePlexusComponent(org.apache.commons.cli.CommandLine cli,
                                  org.codehaus.plexus.PlexusContainer plexus)
                           throws Exception
Specified by:
invokePlexusComponent in interface org.codehaus.plexus.tools.cli.Cli
Specified by:
invokePlexusComponent in class org.codehaus.plexus.tools.cli.AbstractCli
Throws:
Exception


Copyright © 2002-2012 The Apache Software Foundation. All Rights Reserved.