Class BitbucketCloudRepository
-
Field Summary
Fields inherited from class com.atlassian.bamboo.specs.api.builders.repository.VcsRepository
description, name, oid, parent, project, repositoryViewer, TYPE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaccountAuthentication
(@NotNull SharedCredentialsIdentifier sharedCredentialsIdentifier) Selects a previously definedSharedCredentials
to configure account authentication with bitbucket.orgaccountAuthentication
(@NotNull UserPasswordAuthentication userPasswordAuthentication) Specifies username/password Bitbucket Cloud account authentication.Sets a branch to check out.protected BitbucketCloudRepositoryProperties
build()
changeDetection
(VcsChangeDetection vcsChangeDetection) Sets change detection options for this repository.checkoutAuthentication
(@NotNull SharedCredentialsIdentifier sharedCredentialsIdentifier) Selects a previously definedSharedCredentials
which will be used to checkout repository from Bitbucket Cloud.checkoutAuthentication
(@NotNull SshPrivateKeyAuthentication sshPrivateKeyAuthentication) Specifies SSH private key which will be used to checkout repository from Bitbucket Cloud.commandTimeout
(Duration commandTimeout) Specifies how much time is given for git commands to finish.commandTimeoutInMinutes
(int commandTimeoutMinutes) Specifies how much time in minutes is given for git commands to finish.Resets all change detection options to defaults.fetchWholeRepository
(boolean fetchWholeRepository) Enforces (or not) fetching all remote refs from the repository rather than single branch.lfsEnabled
(boolean useLfs) Enables/disables git lfs support.remoteAgentCacheEnabled
(boolean useRemoteAgentCache) Enables/disables caching repository content on the remote and elastic agents.repositorySlug
(@NotNull String owner, @NotNull String repositorySlug) Sets the Bitbucket repository slug to checkout.shallowClonesEnabled
(boolean useShallowClones) Enables/disables shallow clones when checking out from the repository.sshKeyAppliesToSubmodules
(boolean sshKeyAppliesToSubmodules) Enables/disabled authenticating to submodules with SSH key configured for this repository.submodulesEnabled
(boolean useSubmodules) Enables/disables submodule support.verboseLogs
(boolean verboseLogs) Enables/disables verbose logs from git commands.webhookEnabled
(boolean webhookEnabled) Enables webhooks support for the repository.Methods inherited from class com.atlassian.bamboo.specs.api.builders.repository.VcsRepository
description, getIdentifier, getName, getOid, humanReadableId, humanReadableType, name, oid, oid, parent, project, repositoryViewer
-
Constructor Details
-
BitbucketCloudRepository
- Throws:
PropertiesValidationException
-
-
Method Details
-
repositorySlug
public BitbucketCloudRepository repositorySlug(@NotNull @NotNull String owner, @NotNull @NotNull String repositorySlug) Sets the Bitbucket repository slug to checkout. A repository slug is a URL-friendly version of a repository name, automatically generated by Bitbucket Cloud for use in the URL.
This field is required and it must represents existing Bitbucket Cloud repository.
-
branch
Sets a branch to check out. This field is required. -
shallowClonesEnabled
Enables/disables shallow clones when checking out from the repository. With shallow clones on, Bamboo fetches the shallowest commit history possible. Do not use if your build depends on full repository history.
Shallow clones are switched off by default.
Option does nothing with Mercurial type of repository.
-
sshKeyAppliesToSubmodules
Enables/disabled authenticating to submodules with SSH key configured for this repository. -
submodulesEnabled
Enables/disables submodule support. Turned off by default.Option does nothing with Mercurial type of repository.
-
remoteAgentCacheEnabled
Enables/disables caching repository content on the remote and elastic agents. Bamboo uses caching to reduce bandwidth needed when retrieving source code from the repository.
The feature is turned on by default in Git repositories
Option does nothing with Mercurial type of repository.
-
commandTimeout
Specifies how much time is given for git commands to finish. Default is 180 minutes. -
commandTimeoutInMinutes
Specifies how much time in minutes is given for git commands to finish. Default is 180 minutes. -
verboseLogs
Enables/disables verbose logs from git commands. Off by default. -
fetchWholeRepository
Enforces (or not) fetching all remote refs from the repository rather than single branch. Off by default. -
lfsEnabled
Enables/disables git lfs support. Off by default.Option does nothing with Mercurial type of repository.
-
webhookEnabled
Enables webhooks support for the repository. Off by default. -
defaultChangeDetection
Resets all change detection options to defaults. -
changeDetection
Sets change detection options for this repository.- See Also:
-
accountAuthentication
public BitbucketCloudRepository accountAuthentication(@NotNull @NotNull UserPasswordAuthentication userPasswordAuthentication) Specifies username/password Bitbucket Cloud account authentication.
The password can be defined in both Bamboo-encrypted and plain format.
- See Also:
-
checkoutAuthentication
public BitbucketCloudRepository checkoutAuthentication(@NotNull @NotNull SshPrivateKeyAuthentication sshPrivateKeyAuthentication) Specifies SSH private key which will be used to checkout repository from Bitbucket Cloud. If checkout authentication is not configured, the accountAuthentication will be used.
The key and passphrase can be defined in both Bamboo-encrypted and plain format.
- See Also:
-
build
- Specified by:
build
in classVcsRepository<BitbucketCloudRepository,
BitbucketCloudRepositoryProperties> - Throws:
PropertiesValidationException
-