Class GitResourceService
- java.lang.Object
-
- fr.paris.lutece.plugins.releaser.service.github.GitResourceService
-
- All Implemented Interfaces:
IVCSResourceService
- Direct Known Subclasses:
GithubResourceService,GitlabResourceService
public class GitResourceService extends Object implements IVCSResourceService
SvnSiteService.
-
-
Constructor Summary
Constructors Constructor Description GitResourceService()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcheckoutBranch(WorkflowReleaseContext context, String strBranch, Locale locale)Checkout branch.voidcheckoutDevelopBranch(WorkflowReleaseContext context, Locale locale)Checkout develop branch.StringdoCheckoutRepository(WorkflowReleaseContext context, String strLogin, String strPassword)Do checkout repository.StringfetchPom(Site site, String strGitLogin, String strGitPwd)Fetch the pom.xml content from a repositoryStringgetLastRelease(Site site, String strGitLogin, String strGitPwd)Gets the last release found in the SVN repository.voidrollbackRelease(WorkflowReleaseContext context, Locale locale)Rollback release.voidupdateBranch(WorkflowReleaseContext context, String strBranch, Locale locale, String strMessage)Update branch.voidupdateDevelopBranch(WorkflowReleaseContext context, Locale locale, String strMessage)Update develop branch.voidupdateMasterBranch(WorkflowReleaseContext context, Locale locale)Update master branch.
-
-
-
Method Detail
-
fetchPom
public String fetchPom(Site site, String strGitLogin, String strGitPwd)
Fetch the pom.xml content from a repository- Specified by:
fetchPomin interfaceIVCSResourceService- Parameters:
site- the sitestrGitLogin- the str git loginstrGitPwd- the str git pwd- Returns:
- The POM content
-
getLastRelease
public String getLastRelease(Site site, String strGitLogin, String strGitPwd)
Gets the last release found in the SVN repository.- Specified by:
getLastReleasein interfaceIVCSResourceService- Parameters:
site- the sitestrGitLogin- the str git loginstrGitPwd- the str git pwd- Returns:
- The version if found otherwise null
-
doCheckoutRepository
public String doCheckoutRepository(WorkflowReleaseContext context, String strLogin, String strPassword)
Do checkout repository.- Specified by:
doCheckoutRepositoryin interfaceIVCSResourceService- Parameters:
context- the contextstrLogin- the str loginstrPassword- the str password- Returns:
- the string
-
updateDevelopBranch
public void updateDevelopBranch(WorkflowReleaseContext context, Locale locale, String strMessage)
Update develop branch.- Specified by:
updateDevelopBranchin interfaceIVCSResourceService- Parameters:
context- the contextlocale- the localestrMessage- the str message
-
updateBranch
public void updateBranch(WorkflowReleaseContext context, String strBranch, Locale locale, String strMessage)
Update branch.- Specified by:
updateBranchin interfaceIVCSResourceService- Parameters:
context- the contextlocale- the localestrMessage- the str message
-
updateMasterBranch
public void updateMasterBranch(WorkflowReleaseContext context, Locale locale)
Update master branch.- Specified by:
updateMasterBranchin interfaceIVCSResourceService- Parameters:
context- the contextlocale- the locale
-
rollbackRelease
public void rollbackRelease(WorkflowReleaseContext context, Locale locale)
Rollback release.- Specified by:
rollbackReleasein interfaceIVCSResourceService- Parameters:
context- the contextlocale- the locale
-
checkoutDevelopBranch
public void checkoutDevelopBranch(WorkflowReleaseContext context, Locale locale)
Checkout develop branch.- Specified by:
checkoutDevelopBranchin interfaceIVCSResourceService- Parameters:
context- the contextlocale- the locale
-
checkoutBranch
public void checkoutBranch(WorkflowReleaseContext context, String strBranch, Locale locale)
Checkout branch.- Specified by:
checkoutBranchin interfaceIVCSResourceService- Parameters:
context- the contextlocale- the locale
-
-