public class GitOperations extends Object
| Constructor and Description |
|---|
GitOperations(hudson.FilePath workspace,
hudson.model.TaskListener listener,
hudson.EnvVars envVars,
String url) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
checkout(String branch) |
boolean |
cloneTheRepo(String branch) |
boolean |
fetch(String branch,
List<org.eclipse.jgit.transport.RefSpec> refSpecs) |
String |
getCurrentBranch() |
hudson.model.TaskListener |
getListener() |
boolean |
merge(String rev) |
boolean |
pullChangesOfPullrequest(int PR_Number,
String branch) |
boolean |
push(boolean fromHead) |
void |
setCurrentBranch(String currentBranch) |
void |
setEnvVars(hudson.EnvVars envVars) |
void |
setUsernameAndPasswordCredential(com.cloudbees.plugins.credentials.common.StandardUsernameCredentials cred) |
void |
setWorkspace(hudson.FilePath workspace) |
public GitOperations(hudson.FilePath workspace,
hudson.model.TaskListener listener,
hudson.EnvVars envVars,
String url)
throws IOException,
InterruptedException
IOExceptionInterruptedExceptionpublic void setEnvVars(hudson.EnvVars envVars)
throws IOException,
InterruptedException
IOExceptionInterruptedExceptionpublic hudson.model.TaskListener getListener()
public void setWorkspace(hudson.FilePath workspace)
throws IOException,
InterruptedException
IOExceptionInterruptedExceptionpublic String getCurrentBranch()
public void setCurrentBranch(String currentBranch)
public boolean cloneTheRepo(String branch)
public boolean checkout(String branch)
public boolean pullChangesOfPullrequest(int PR_Number,
String branch)
throws InterruptedException
InterruptedExceptionpublic boolean merge(String rev)
public boolean push(boolean fromHead)
public void setUsernameAndPasswordCredential(com.cloudbees.plugins.credentials.common.StandardUsernameCredentials cred)
Copyright © 2016–2018. All rights reserved.