public class GitHubSCMSource
extends jenkins.plugins.git.AbstractGitSCMSource
| Modifier and Type | Class and Description |
|---|---|
static class |
GitHubSCMSource.DescriptorImpl |
| Modifier and Type | Field and Description |
|---|---|
static String |
GITHUB_URL |
static String |
VALID_GIT_SHA1 |
static String |
VALID_GITHUB_REPO_NAME |
static String |
VALID_GITHUB_USER_NAME |
| Constructor and Description |
|---|
GitHubSCMSource(String id,
String apiUri,
String checkoutCredentialsId,
String scanCredentialsId,
String repoOwner,
String repository) |
| Modifier and Type | Method and Description |
|---|---|
void |
afterSave() |
hudson.scm.SCM |
build(jenkins.scm.api.SCMHead head,
jenkins.scm.api.SCMRevision revision) |
protected jenkins.scm.api.SCMProbe |
createProbe(jenkins.scm.api.SCMHead head,
jenkins.scm.api.SCMRevision revision) |
protected jenkins.scm.api.SCMRevision |
doRetrieve(jenkins.scm.api.SCMHead head,
hudson.model.TaskListener listener,
org.kohsuke.github.GHRepository repo) |
String |
getApiUri() |
boolean |
getBuildForkPRHead() |
boolean |
getBuildForkPRMerge() |
boolean |
getBuildOriginBranch() |
boolean |
getBuildOriginBranchWithPR() |
boolean |
getBuildOriginPRHead() |
boolean |
getBuildOriginPRMerge() |
String |
getCheckoutCredentialsId() |
String |
getCredentialsId()
Returns the effective credentials used to check out sources:
null - anonymous access
SAME - represents that we want to use the same as scan credentials
UUID - represents the credentials identifier
|
String |
getExcludes() |
String |
getIncludes() |
String |
getPronoun() |
protected List<org.eclipse.jgit.transport.RefSpec> |
getRefSpecs() |
String |
getRemote() |
String |
getRepoOwner() |
String |
getRepository() |
String |
getScanCredentialsId() |
jenkins.scm.api.SCMRevision |
getTrustedRevision(jenkins.scm.api.SCMRevision revision,
hudson.model.TaskListener listener) |
RepositoryUriResolver |
getUriResolver()
Returns a
RepositoryUriResolver according to credentials configuration. |
protected boolean |
isCategoryEnabled(jenkins.scm.api.SCMHeadCategory category) |
protected boolean |
isExcluded(String branchName) |
protected jenkins.scm.api.SCMRevision |
retrieve(jenkins.scm.api.SCMHead head,
hudson.model.TaskListener listener) |
protected void |
retrieve(jenkins.scm.api.SCMSourceCriteria criteria,
jenkins.scm.api.SCMHeadObserver observer,
jenkins.scm.api.SCMHeadEvent<?> event,
hudson.model.TaskListener listener) |
protected List<hudson.model.Action> |
retrieveActions(jenkins.scm.api.SCMHead head,
jenkins.scm.api.SCMHeadEvent event,
hudson.model.TaskListener listener) |
protected List<hudson.model.Action> |
retrieveActions(jenkins.scm.api.SCMSourceEvent event,
hudson.model.TaskListener listener) |
void |
setBuildForkPRHead(boolean buildForkPRHead) |
void |
setBuildForkPRMerge(boolean buildForkPRMerge) |
void |
setBuildOriginBranch(boolean buildOriginBranch) |
void |
setBuildOriginBranchWithPR(boolean buildOriginBranchWithPR) |
void |
setBuildOriginPRHead(boolean buildOriginPRHead) |
void |
setBuildOriginPRMerge(boolean buildOriginPRMerge) |
void |
setExcludes(String excludes) |
void |
setIncludes(String includes) |
getCacheDir, getCacheEntry, getCacheLock, getCredentials, getRemoteConfigs, getRemoteName, retrievebuild, canProbe, checkInterrupt, defaultListener, equals, fetch, fetch, fetch, fetch, fetch, fetch, fetch, fetchActions, fetchActions, fetchActions, fetchRevisions, fromSCMFileSystem, getCategories, getCriteria, getDescriptor, getId, getOwner, hashCode, newProbe, parentHeads, parentRevisions, retrieve, retrieve, retrieve, retrieve, retrieveActions, retrieveRevisions, setOwner, toStringpublic static final String VALID_GITHUB_REPO_NAME
public static final String VALID_GITHUB_USER_NAME
public static final String VALID_GIT_SHA1
public static final String GITHUB_URL
@CheckForNull public String getApiUri()
@CheckForNull public String getCredentialsId()
getCredentialsId in class jenkins.plugins.git.AbstractGitSCMSource@CheckForNull public String getScanCredentialsId()
@CheckForNull public String getCheckoutCredentialsId()
public String getRepoOwner()
public String getRepository()
public String getPronoun()
getPronoun in class jenkins.scm.api.SCMSourceprotected List<org.eclipse.jgit.transport.RefSpec> getRefSpecs()
getRefSpecs in class jenkins.plugins.git.AbstractGitSCMSourcepublic RepositoryUriResolver getUriResolver()
RepositoryUriResolver according to credentials configuration.RepositoryUriResolver@NonNull public String getIncludes()
getIncludes in class jenkins.plugins.git.AbstractGitSCMSource@DataBoundSetter
public void setIncludes(@NonNull
String includes)
@NonNull public String getExcludes()
getExcludes in class jenkins.plugins.git.AbstractGitSCMSource@DataBoundSetter
public void setExcludes(@NonNull
String excludes)
public boolean getBuildOriginBranch()
@DataBoundSetter public void setBuildOriginBranch(boolean buildOriginBranch)
public boolean getBuildOriginBranchWithPR()
@DataBoundSetter public void setBuildOriginBranchWithPR(boolean buildOriginBranchWithPR)
public boolean getBuildOriginPRMerge()
@DataBoundSetter public void setBuildOriginPRMerge(boolean buildOriginPRMerge)
public boolean getBuildOriginPRHead()
@DataBoundSetter public void setBuildOriginPRHead(boolean buildOriginPRHead)
public boolean getBuildForkPRMerge()
@DataBoundSetter public void setBuildForkPRMerge(boolean buildForkPRMerge)
public boolean getBuildForkPRHead()
@DataBoundSetter public void setBuildForkPRHead(boolean buildForkPRHead)
public String getRemote()
getRemote in class jenkins.plugins.git.AbstractGitSCMSourceprotected final void retrieve(@CheckForNull
jenkins.scm.api.SCMSourceCriteria criteria,
@NonNull
jenkins.scm.api.SCMHeadObserver observer,
@CheckForNull
jenkins.scm.api.SCMHeadEvent<?> event,
@NonNull
hudson.model.TaskListener listener)
throws IOException,
InterruptedException
retrieve in class jenkins.scm.api.SCMSourceIOExceptionInterruptedExceptionprotected boolean isExcluded(String branchName)
isExcluded in class jenkins.plugins.git.AbstractGitSCMSource@NonNull
protected jenkins.scm.api.SCMProbe createProbe(@NonNull
jenkins.scm.api.SCMHead head,
@CheckForNull
jenkins.scm.api.SCMRevision revision)
throws IOException
createProbe in class jenkins.scm.api.SCMSourceIOException@CheckForNull
protected jenkins.scm.api.SCMRevision retrieve(jenkins.scm.api.SCMHead head,
hudson.model.TaskListener listener)
throws IOException,
InterruptedException
retrieve in class jenkins.plugins.git.AbstractGitSCMSourceIOExceptionInterruptedExceptionprotected jenkins.scm.api.SCMRevision doRetrieve(jenkins.scm.api.SCMHead head,
hudson.model.TaskListener listener,
org.kohsuke.github.GHRepository repo)
throws IOException,
InterruptedException
IOExceptionInterruptedExceptionpublic hudson.scm.SCM build(jenkins.scm.api.SCMHead head,
jenkins.scm.api.SCMRevision revision)
build in class jenkins.plugins.git.AbstractGitSCMSourcepublic jenkins.scm.api.SCMRevision getTrustedRevision(jenkins.scm.api.SCMRevision revision,
hudson.model.TaskListener listener)
throws IOException,
InterruptedException
getTrustedRevision in class jenkins.scm.api.SCMSourceIOExceptionInterruptedExceptionprotected boolean isCategoryEnabled(@NonNull
jenkins.scm.api.SCMHeadCategory category)
isCategoryEnabled in class jenkins.scm.api.SCMSource@NonNull protected List<hudson.model.Action> retrieveActions(@NonNull jenkins.scm.api.SCMHead head, @CheckForNull jenkins.scm.api.SCMHeadEvent event, @NonNull hudson.model.TaskListener listener) throws IOException
retrieveActions in class jenkins.scm.api.SCMSourceIOException@NonNull protected List<hudson.model.Action> retrieveActions(@CheckForNull jenkins.scm.api.SCMSourceEvent event, @NonNull hudson.model.TaskListener listener) throws IOException
retrieveActions in class jenkins.scm.api.SCMSourceIOExceptionpublic void afterSave()
afterSave in class jenkins.scm.api.SCMSourceCopyright © 2016. All rights reserved.