Interface GitArchiveBuilder
- All Superinterfaces:
com.atlassian.bitbucket.scm.CommandBuilderSupport<GitArchiveBuilder>,GitCommandBuilderSupport<GitArchiveBuilder>
A builder which can be used to construct a
command
for running git archive.
git archive's -o and --output flags are intentionally not supported by this builder,
to discourage storing generated archives on the server. Should there by an explicit need to store an archive, the
caller can write a custom CommandOutputHandler to do so.
- Since:
- 5.1
-
Field Summary
Fields inherited from interface com.atlassian.bitbucket.scm.git.command.GitCommandBuilderSupport
ENV_AUTHOR_DATE, ENV_AUTHOR_EMAIL, ENV_AUTHOR_NAME, ENV_COMMITTER_DATE, ENV_COMMITTER_EMAIL, ENV_COMMITTER_NAME -
Method Summary
Modifier and TypeMethodDescriptionClears anypathswhich have been applied to filter the files included in the archive.format(GitArchiveFormat value) Specifies the format for the generated archive.Specifies a path to filter the files included in the archive.Specifies paths to filter the files included in the archive.Specifies one or more paths to filter the files included in the archive.Specifies a prefix to be applied to files included in the archive.Specifies the revision which should be archived.Methods inherited from interface com.atlassian.bitbucket.scm.CommandBuilderSupport
clearEnvironment, defaultExitHandler, exitHandler, removeEnvironment, withEnvironmentMethods inherited from interface com.atlassian.bitbucket.scm.git.command.GitCommandBuilderSupport
alternate, alternates, alternates, author, author, author, build, commitish, committer, committer, committer, treeish, withConfiguration, withConfiguration, withConfiguration, withConfiguration
-
Method Details
-
clearPaths
Clears anypathswhich have been applied to filter the files included in the archive.- Returns:
this
-
format
Specifies the format for the generated archive. If no format is specified, the default forgit archivewill be used.- Parameters:
value- the desired format, ornullto use the default- Returns:
this
-
path
Specifies a path to filter the files included in the archive.- Parameters:
value- the filter path, which will be ignored ifnull- Returns:
this
-
paths
Specifies one or more paths to filter the files included in the archive.- Parameters:
value- the first filter path, which will be ignored ifnullvalues- additional filter paths, which will be ignored ifnull- Returns:
this
-
paths
Specifies paths to filter the files included in the archive.- Parameters:
values- some number of filter paths, which will be ignored ifnull- Returns:
this
-
prefix
Specifies a prefix to be applied to files included in the archive. By default, no prefix is applied.- Parameters:
value- the prefix to use, ornullto not apply a prefix- Returns:
this
-
rev
Specifies the revision which should be archived. If this method isn't called,HEADwill be used to archive the default branch for the repository.- Parameters:
value- the revision to archive- Returns:
this
-