Class GitRepository
java.lang.Object
pl.allegro.tech.build.axion.release.infrastructure.git.GitRepository
- All Implemented Interfaces:
ScmRepository
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidattachRemote(String remoteName, String remoteUrl) booleanvoidvoidvoidfetchTags(ScmIdentity identity, String remoteName) This fetch method behaves like git fetch, meaning it only fetches thing without merging.org.eclipse.jgit.api.GitisIdenticalForPath(String path, String latestChangeRevision, String tagCommitRevision) booleanlastLogMessages(int messageCount) latestTags(List<Pattern> patterns) latestTags(List<Pattern> patterns, String sinceCommit) org.eclipse.jgit.api.StatusintpositionOfLastChangeIn(String path, List<String> excludeSubFolders, Set<String> dependenciesFolders) push(ScmIdentity identity, ScmPushOptions pushOptions) push(ScmIdentity identity, ScmPushOptions pushOptions, boolean all) booleanremoteAttached(String remoteName) voidtaggedCommits(List<Pattern> patterns)
-
Constructor Details
-
GitRepository
-
-
Method Details
-
fetchTags
This fetch method behaves like git fetch, meaning it only fetches thing without merging. As a result, any fetched tags will not be visible via GitRepository tag listing methods because they do commit-tree walk, not tag listing.This method is only useful if you have bare repo on CI systems, where merge is not neccessary, because newest version of content has already been fetched.
- Specified by:
fetchTagsin interfaceScmRepository
-
tag
- Specified by:
tagin interfaceScmRepository
-
dropTag
- Specified by:
dropTagin interfaceScmRepository
-
push
- Specified by:
pushin interfaceScmRepository
-
push
-
attachRemote
- Specified by:
attachRemotein interfaceScmRepository
-
commit
- Specified by:
commitin interfaceScmRepository
-
positionOfLastChangeIn
public ScmPosition positionOfLastChangeIn(String path, List<String> excludeSubFolders, Set<String> dependenciesFolders) - Specified by:
positionOfLastChangeInin interfaceScmRepository
-
isIdenticalForPath
public Boolean isIdenticalForPath(String path, String latestChangeRevision, String tagCommitRevision) - Specified by:
isIdenticalForPathin interfaceScmRepository
-
currentPosition
- Specified by:
currentPositionin interfaceScmRepository
-
latestTags
- Specified by:
latestTagsin interfaceScmRepository
-
latestTags
- Specified by:
latestTagsin interfaceScmRepository
-
taggedCommits
- Specified by:
taggedCommitsin interfaceScmRepository
-
remoteAttached
- Specified by:
remoteAttachedin interfaceScmRepository
-
checkUncommittedChanges
public boolean checkUncommittedChanges()- Specified by:
checkUncommittedChangesin interfaceScmRepository- Returns:
- true when there are uncommitted changes. This means: not clean
-
numberOfCommitsAheadOrBehindRemote
public int numberOfCommitsAheadOrBehindRemote()- Specified by:
numberOfCommitsAheadOrBehindRemotein interfaceScmRepository
-
listChanges
public org.eclipse.jgit.api.Status listChanges() -
isLegacyDefTagnameRepo
public boolean isLegacyDefTagnameRepo()- Specified by:
isLegacyDefTagnameRepoin interfaceScmRepository
-
lastLogMessages
- Specified by:
lastLogMessagesin interfaceScmRepository
-
getJgitRepository
public org.eclipse.jgit.api.Git getJgitRepository()
-