Package org.eclipse.jgit.pgm
Class Clone
java.lang.Object
org.eclipse.jgit.pgm.TextBuiltin
org.eclipse.jgit.pgm.AbstractFetchCommand
org.eclipse.jgit.pgm.Clone
- All Implemented Interfaces:
CloneCommand.Callback
-
Nested Class Summary
Nested classes/interfaces inherited from class org.eclipse.jgit.pgm.TextBuiltin
TextBuiltin.TerminatedByHelpException
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
checkingOut
(AnyObjectId commit, String path) Notify checkout of commitvoid
cloningSubmodule
(String path) Notify starting to clone a submodule.void
initializedSubmodules
(Collection<String> submodules) Notify initialized submodules.protected final boolean
If this command requires a repository.protected void
run()
Perform the actions of this command.Methods inherited from class org.eclipse.jgit.pgm.AbstractFetchCommand
showFetchResult, showRemoteMessages
Methods inherited from class org.eclipse.jgit.pgm.TextBuiltin
abbreviateRef, containsHelp, die, die, die, die, execute, getErrorWriter, getOutputWriter, getRepository, getResourceBundle, init, initRaw, parseArguments, printUsage, printUsageAndExit, printUsageAndExit, resolve, setCommandName
-
Field Details
-
remoteName
-
branch
-
noCheckout
private boolean noCheckout -
isBare
private boolean isBare -
isMirror
private boolean isMirror -
quiet
-
cloneSubmodules
private boolean cloneSubmodules -
timeout
int timeout -
sourceUri
-
localName
-
-
Constructor Details
-
Clone
Clone()
-
-
Method Details
-
requiresRepository
protected final boolean requiresRepository()If this command requires a repository.- Overrides:
requiresRepository
in classTextBuiltin
- Returns:
- true if
TextBuiltin.db
/TextBuiltin.getRepository()
is required
-
run
Perform the actions of this command.This method should only be invoked by
TextBuiltin.execute(String[])
.- Specified by:
run
in classTextBuiltin
- Throws:
Exception
- an error occurred while processing the command. The main framework will catch the exception and print a message on standard error.
-
initializedSubmodules
Notify initialized submodules.- Specified by:
initializedSubmodules
in interfaceCloneCommand.Callback
- Parameters:
submodules
- the submodules
-
cloningSubmodule
Notify starting to clone a submodule.- Specified by:
cloningSubmodule
in interfaceCloneCommand.Callback
- Parameters:
path
- the submodule path
-
checkingOut
Notify checkout of commit- Specified by:
checkingOut
in interfaceCloneCommand.Callback
- Parameters:
commit
- the id of the commit being checked outpath
- the submodule path
-