Package com.atlassian.bamboo.vcs.runtime
Interface UpdatingVcsWorkingCopyManager
- All Superinterfaces:
VcsWorkingCopyManager
- All Known Implementing Classes:
BitbucketCloudWorkingCopyManager,BitbucketServerWorkingCopyManager,GitHubWorkingCopyManager,GitWorkingCopyManager
VcsWorkingCopyManager that can update source on vcs server.- Since:
- 5.14
-
Method Summary
Modifier and TypeMethodDescription@NotNull VcsWorkingCopycommitLocal(@NotNull VcsWorkingCopy workingCopy, @NotNull VcsRepositoryData vcsRepositoryData, @NotNull String commitMessage) Create a local commit.default voidstageChanges(@NotNull VcsWorkingCopy workingCopy, @NotNull VcsRepositoryData repositoryData, @NotNull Collection<String> pathsToAdd) Stage changes for committing.@NotNull VcsWorkingCopyupdateRemote(@NotNull VcsWorkingCopy workingCopy, @NotNull VcsRepositoryData vcsRepositoryData, @NotNull String commitMessage) Update remote repository.Methods inherited from interface com.atlassian.bamboo.vcs.runtime.VcsWorkingCopyManager
retrieveSourceCode, updateToLatestRevision
-
Method Details
-
stageChanges
default void stageChanges(@NotNull @NotNull VcsWorkingCopy workingCopy, @NotNull @NotNull VcsRepositoryData repositoryData, @NotNull @NotNull Collection<String> pathsToAdd) throws RepositoryException Stage changes for committing. If staging is not required or supported by repository, this method should do nothing.Staging logic may differ between repository types.
- Parameters:
workingCopy- workspace to perform the stagingrepositoryData- configuration of repositorypathsToAdd- paths, relative to working copy directory, to stage for committing; if empty, all modified files from working copy directory should be staged- Throws:
RepositoryException
-
commitLocal
@NotNull @NotNull VcsWorkingCopy commitLocal(@NotNull @NotNull VcsWorkingCopy workingCopy, @NotNull @NotNull VcsRepositoryData vcsRepositoryData, @NotNull @NotNull String commitMessage) throws RepositoryException Create a local commit. The exact meaning of this operation depends on repository type. In particular, it can be no-op for certain repository types, for example SVN. Intended use: creating a private revision that can be used later in the build.- Parameters:
workingCopy-vcsRepositoryData-commitMessage-- Returns:
- updated state of local working copy
- Throws:
RepositoryException
-
updateRemote
@NotNull @NotNull VcsWorkingCopy updateRemote(@NotNull @NotNull VcsWorkingCopy workingCopy, @NotNull @NotNull VcsRepositoryData vcsRepositoryData, @NotNull @NotNull String commitMessage) throws RepositoryException Update remote repository. The exact meaning of this operation depends on repository type. In DVCS case this should push pre-existing local commit to remote repository. In traditional vcs, like Subversion, this should execute commit operation. Intended use: publishing changes to the world.- Parameters:
workingCopy-vcsRepositoryData-commitMessage- - implementors are free to ignore this parameter.- Returns:
- updated state of local working copy
- Throws:
RepositoryException
-