public class GitStatusConsumer extends Object implements org.codehaus.plexus.util.cli.StreamConsumer
| Constructor and Description |
|---|
GitStatusConsumer(ScmLogger logger,
File workingDirectory)
Consumer when workingDirectory and repositoryRootDirectory are the same
|
GitStatusConsumer(ScmLogger logger,
File workingDirectory,
ScmFileSet scmFileSet)
Assuming that you have to discover the repositoryRoot, this is how you can get the
relativeRepositoryPath |
GitStatusConsumer(ScmLogger logger,
File workingDirectory,
URI relativeRepositoryPath)
Assuming that you have to discover the repositoryRoot, this is how you can get the
relativeRepositoryPath |
GitStatusConsumer(ScmLogger logger,
File workingDirectory,
URI relativeRepositoryPath,
ScmFileSet scmFileSet)
Assuming that you have to discover the repositoryRoot, this is how you can get the
relativeRepositoryPath |
| Modifier and Type | Method and Description |
|---|---|
void |
consumeLine(String line) |
List<ScmFile> |
getChangedFiles() |
protected static String |
resolvePath(String fileEntry,
URI path) |
static URI |
resolveURI(String fileEntry,
URI path) |
static URI |
uriFromPath(String path)
Create an URI whose getPath() returns the given path and getScheme() returns null.
|
public GitStatusConsumer(ScmLogger logger, File workingDirectory)
logger - the loggerworkingDirectory - the working directorypublic GitStatusConsumer(ScmLogger logger, File workingDirectory, URI relativeRepositoryPath)
relativeRepositoryPath
URI.create( repositoryRoot ).relativize( fileSet.getBasedir().toURI() )
logger - the loggerworkingDirectory - the working directoryrelativeRepositoryPath - the working directory relative to the repository rootGitStatusCommand.createRevparseShowPrefix(ScmFileSet)public GitStatusConsumer(ScmLogger logger, File workingDirectory, ScmFileSet scmFileSet)
relativeRepositoryPath
URI.create( repositoryRoot ).relativize( fileSet.getBasedir().toURI() )
logger - the loggerworkingDirectory - the working directoryscmFileSet - fileset with includes and excludesGitStatusCommand.createRevparseShowPrefix(ScmFileSet)public GitStatusConsumer(ScmLogger logger, File workingDirectory, URI relativeRepositoryPath, ScmFileSet scmFileSet)
relativeRepositoryPath
URI.create( repositoryRoot ).relativize( fileSet.getBasedir().toURI() )
logger - the loggerworkingDirectory - the working directoryrelativeRepositoryPath - the working directory relative to the repository rootscmFileSet - fileset with includes and excludesGitStatusCommand.createRevparseShowPrefix(ScmFileSet)public void consumeLine(String line)
consumeLine in interface org.codehaus.plexus.util.cli.StreamConsumerprotected static String resolvePath(String fileEntry, URI path)
public static URI resolveURI(String fileEntry, URI path)
fileEntry - the fileEntry, must not be nullpath - the path, must not be nullpublic static URI uriFromPath(String path)
path - the path.public List<ScmFile> getChangedFiles()
Copyright © 2003–2021 The Apache Software Foundation. All rights reserved.