Overview

A quick example:

node {
    sh 'echo hello world'
}

You can write any Groovy code you need, using Java API calls plus the GDK. You can also call Jenkins APIs and APIs in Jenkins plugins. (If Use Groovy Sandbox is checked, or you are not an administrator, not all APIs will be available.)

There are many special build steps available, like node and sh in the example. Below is a reference listing all steps available with your current set of plugins; other plugins offering Pipeline integration may be available on the update center.

Step parameters are given as key-value pairs; if there is just one mandatory parameter the name may be omitted, so

readFile 'build.properties'

is a shortcut for

readFile file: 'build.properties'

but if you specify multiple parameters they must all be named:

readFile file: 'build.properties', encoding: 'ISO-8859-1'

Many steps require complex nested configuration for a parameter. (And some nested configuration objects in turn have object-typed parameters.) There are three ways these nested objects may be specified, in decreasing order of preference:

  1. Some configuration objects define custom symbols. These are used with a notation looking like a step call, or other function call taking a map of named parameters:

    splitTests count(3)

    or to spell out the mandatory parameter names:

    splitTests parallelism: count(size: 3)

    Compare to the equivalent using the older second syntax option:

    splitTests parallelism: [$class: 'CountDrivenParallelism', size: 3]

    Some Pipeline steps delegating to a single object allow the actual step name to be omitted where unambiguous, so you can write simply:

    archiveArtifacts '**.txt'

    rather than:

    step([$class: 'ArtifactArchiver', artifacts: '**.txt'])

    The nested configuration is an actual value which can be saved into variables etc.:

    def parallelism(deterministic) {
        deterministic ? count(3) : time(15)
    }
    splitTests parallelism(true)
  2. As maps of parameters. Default values may be omitted. (Note that [1, 2, 3] is a list in Groovy whereas [a: 1, b: 2, c: 3] is a map.)

    The special map key $class is used to represent the simple or (where necessary) fully-qualified class name of the object being requested. $class may be omitted where the containing parameter allows only a single kind of nested object (or list of them):

    checkout([$class: 'GitSCM', userRemoteConfigs: [[url: 'git://…'], extensions: [[$class: 'CleanBeforeCheckout']]])

    In this example, GitSCM must be specified to distinguish the kind of SCM used by the delegate of checkout (the single mandatory parameter name delegate can be omitted), and CleanBeforeCheckout must be specified to distinguish the kind of GitSCMExtension used by the extensions of GitSCM—a “heterogeneous” list; but $class: 'UserRemoteConfig' may be omitted since the userRemoteConfigs of GitSCM are defined to contain only UserRemoteConfigs—it is a “homogeneous” list. (No such omission is permitted for homogeneous lists in the first syntax.)

    Note that in cases where a single parameter is given, with the name omitted, and that parameter is a map, it must be enclosed in parentheses to avoid a syntactic ambiguity.

  3. As actual Java objects:

    import hudson.plugins.git.*
    import hudson.plugins.git.extensions.impl.*
    checkout(new GitSCM([new UserRemoteConfig('git://…', null, null, null)], null, false, [], null, null, [new CleanBeforeCheckout()]))

    Besides the verbosity, such scripts cannot generally run in the Groovy sandbox without numerous signature approvals, making this mode unusable in typical secured Jenkins installations.

The Snippet Generator tool will produce the first syntax when possible, falling back to the second syntax using $class where necessary. Symbols are available in Jenkins core 2.2 and later, and some plugins.

DSL Reference

Steps

addEmbeddableBadgeConfiguration: Add an Embeddable Badge Configuration
id
Type:String
animatedOverlayColor (optional)
Type:String
color (optional)
Type:String
link (optional)
Type:String
status (optional)
Type:String
subject (optional)
Type:String
ansiColor: Color ANSI Console Output
Adds support for standard ANSI escape sequences, including color, to Console Output.
colorMapName
Type:String
archiveArtifacts: Archive the artifacts
Archives the build artifacts (for example, distribution zip files or jar files) so that they can be downloaded later. Archived files will be accessible from the Jenkins webpage.
Normally, Jenkins keeps artifacts for a build as long as a build log itself is kept, but if you don't need old artifacts and would rather save disk space, you can do so.

Note that the Maven job type automatically archives any produced Maven artifacts. Any artifacts configured here will be archived on top of that. Automatic artifact archiving can be disabled under the advanced Maven options.

The Pipeline Snippet Generator generates this example when all arguments are set to true (some arguments by default are true):
archiveArtifacts artifacts: '**/*.txt',
                   allowEmptyArchive: true,
                   fingerprint: true,
                   onlyIfSuccessful: true

artifacts
You can use wildcards like 'module/dist/**/*.zip'. See the includes attribute of Ant fileset for the exact format -- except that "," (comma) is the only supported separator. The base directory is the workspace. You can only archive files that are located in your workspace.

Here are some examples of usage for pipeline:

  • How to archive multiple artifacts from a specific folder:
    archiveArtifacts artifacts: 'target/*.jar'

  • How to archive multiple artifacts with different patterns:
    archiveArtifacts artifacts: 'target/*.jar, target/*.war'

  • How to archive multiple nested artifacts:
    archiveArtifacts artifacts: '**/*.jar'

Type:String
allowEmptyArchive (optional)
Normally, a build fails if archiving returns zero artifacts. This option allows the archiving process to return nothing without failing the build. Instead, the build will simply throw a warning.
Type:boolean
caseSensitive (optional)
Artifact archiver uses Ant org.apache.tools.ant.DirectoryScanner which by default is case sensitive. For instance, if the job produces *.hpi files, pattern "**/*.HPI" will fail to find them.

This option can be used to disable case sensitivity. When it's unchecked, pattern "**/*.HPI" will match any *.hpi files, or pattern "**/cAsEsEnSiTiVe.jar" will match a file called caseSensitive.jar.
Type:boolean
defaultExcludes (optional)
Type:boolean
excludes (optional)
Optionally specify the 'excludes' pattern, such as "foo/bar/**/*". Use "," to set a list of patterns. A file that matches this mask will not be archived even if it matches the mask specified in 'files to archive' section.
Type:String
fingerprint (optional)
Type:boolean
followSymlinks (optional)
By disabling this option all symbolic links found in the workspace will be ignored.
Type:boolean
onlyIfSuccessful (optional)
Type:boolean
associateTag: Associate Tag (Nexus Repository Manager 3.x)
nexusInstanceId
Type:String
tagName
The tag which will be applied to components matching the specified search criteria
Type:String
search
The search criteria used to locate components on the target Nexus Repository Manager server. For more details, please see Search API
Array/List:
Nested object
key
Type:String
value
Type:String
bat: Windows Batch Script
script
Executes a Batch script. Multiple lines allowed. When using the returnStdout flag, you probably wish to prefix this with @, lest the command itself be included in the output.
Type:String
encoding (optional)
Encoding of process output. In the case of returnStdout, applies to the return value of this step; otherwise, or always for standard error, controls how text is copied to the build log. If unspecified, uses the system default encoding of the node on which the step is run. If there is any expectation that process output might include non-ASCII characters, it is best to specify the encoding explicitly. For example, if you have specific knowledge that a given process is going to be producing UTF-8 yet will be running on a node with a different system encoding (typically Windows, since every Linux distribution has defaulted to UTF-8 for a long time), you can ensure correct output by specifying: encoding: 'UTF-8'
Type:String
label (optional)
Label to be displayed in the pipeline step view and blue ocean details for the step instead of the step type. So the view is more meaningful and domain specific instead of technical.
Type:String
returnStatus (optional)
Normally, a script which exits with a nonzero status code will cause the step to fail with an exception. If this option is checked, the return value of the step will instead be the status code. You may then compare it to zero, for example.
Type:boolean
returnStdout (optional)
If checked, standard output from the task is returned as the step value as a String, rather than being printed to the build log. (Standard error, if any, will still be printed to the log.) You will often want to call .trim() on the result to strip off a trailing newline.
Type:boolean
build: Build a job

Trigger a new build for a given job.

Use the Pipeline Snippet Generator to generate a sample pipeline script for the build step.

job
Name of a downstream job to build. May be another Pipeline job, but more commonly a freestyle or other project. Use a simple name if the job is in the same folder as this upstream Pipeline job; otherwise can use relative paths like ../sister-folder/downstream or absolute paths like /top-level-folder/nested-folder/downstream.
Type:String
parameters (optional)
A list of parameters to pass to the downstream job. When passing secrets to downstream jobs, prefer credentials parameters over password parameters. See the documentation for details.
Array/List:
Nested choice of objects
booleanParam
name
Type:String
value
Type:boolean
credentials
name
Type:String
value
Type:String
description
Type:String
file
name
Type:String
file
Nested choice of objects
$class: 'ListSubversionTagsParameterValue'
name
Type:String
tagsDir
Type:String
tag
Type:String
password
name
Type:String
value
org.kohsuke.stapler.NoStaplerConstructorException: There's no @DataBoundConstructor on any constructor of class hudson.util.Secret
description
Type:String
$class: 'PromotedBuildParameterValue'
name
Type:String
runId
Type:String
description
Type:String
run
name
Type:String
runId
Type:String
description
Type:String
string
name
Type:String
value
Type:String
text
name
Type:String
value
Type:String
propagate (optional)

If enabled (default state), then the result of this step is that of the downstream build (e.g., success, unstable, failure, not built, or aborted). If disabled, then this step succeeds even if the downstream build is unstable, failed, etc.; use the result property of the return value as needed.

Type:boolean
quietPeriod (optional)
Optional alternate quiet period (in seconds) before building. If unset, defaults to the quiet period defined by the downstream project (or finally to the system-wide default quiet period).
Type:int
wait (optional)
If true, the pipeline will wait for the result of the build step before jumping to the next step. Defaults to true.
Type:boolean
catchError: Catch error and set build result to failure
If the body throws an exception, mark the build as a failure, but nonetheless continue to execute the Pipeline from the statement following the catchError step. The behavior of the step when an exception is thrown can be configured to print a message, set a build result other than failure, change the stage result, or ignore certain kinds of exceptions that are used to interrupt the build.

This step is most useful when used in Declarative Pipeline or with the options to set the stage result or ignore build interruptions. Otherwise, consider using plain try-catch(-finally) blocks. It is also useful when using certain post-build actions (notifiers) originally defined for freestyle projects which pay attention to the result of the ongoing build.

node {
    catchError {
        sh 'might fail'
    }
    step([$class: 'Mailer', recipients: 'admin@somewhere'])
}

If the shell step fails, the Pipeline build’s status will be set to failed, so that the subsequent mail step will see that this build is failed. In the case of the mail sender, this means that it will send mail. (It may also send mail if this build succeeded but previous ones failed, and so on.) Even in that case, this step can be replaced by the following idiom:

node {
    try {
        sh 'might fail'
    } catch (err) {
        echo "Caught: ${err}"
        currentBuild.result = 'FAILURE'
    }
    step([$class: 'Mailer', recipients: 'admin@somewhere'])
}

For other cases, plain try-catch(-finally) blocks may be used:

node {
    sh './set-up.sh'
    try {
        sh 'might fail'
        echo 'Succeeded!'
    } catch (err) {
        echo "Failed: ${err}"
    } finally {
        sh './tear-down.sh'
    }
    echo 'Printed whether above succeeded or failed.'
}
// …and the pipeline as a whole succeeds

See this document for background.

buildResult (optional)
If an error is caught, the overall build result will be set to this value. Note that the build result can only get worse, so you cannot change the result to SUCCESS if the current result is UNSTABLE or worse. Use SUCCESS or null to keep the build result from being set when an error is caught.
Type:String
catchInterruptions (optional)
If true, certain types of exceptions that are used to interrupt the flow of execution for Pipelines will be caught and handled by the step. If false, those types of exceptions will be caught and immediately rethrown. Examples of these types of exceptions include those thrown when a build is manually aborted through the UI and those thrown by the timeout step. Defaults to true.
Type:boolean
message (optional)
A message that will be logged to the console if an error is caught. If the stage result is specified, the message will also be associated with that result and may be shown in visualizations.
Type:String
stageResult (optional)
If an error is caught, the stage result will be set to this value. If a message was specified, the message will be associated with this result. Use SUCCESS or null to keep the stage result from being set when an error is caught.
Type:String
checkout: Check out from version control
scm
Nested choice of objects
$class: 'GitSCM'

The git plugin provides fundamental git operations for Jenkins projects. It can poll, fetch, checkout, and merge contents of git repositories.

The git plugin provides an SCM implementation to be used with the Pipeline SCM checkout step. The Pipeline Syntax Snippet Generator guides the user to select git plugin checkout options and provides online help for each of the options.

userRemoteConfigs
Specify the repository to track. This can be a URL or a local file path. Note that for super-projects (repositories with submodules), only a local file path or a complete URL is valid. The following are examples of valid git URLs.
  • ssh://git@github.com/github/git.git
  • git@github.com:github/git.git (short notation for ssh protocol)
  • ssh://user@other.host.com/~/repos/R.git (to access the repos/R.git repository in the user's home directory)
  • https://github.com/github/git.git

If the repository is a super-project, the location from which to clone submodules is dependent on whether the repository is bare or non-bare (i.e. has a working directory).
  • If the super-project is bare, the location of the submodules will be taken from .gitmodules.
  • If the super-project is not bare, it is assumed that the repository has each of its submodules cloned and checked out appropriately. Thus, the submodules will be taken directly from a path like ${SUPER_PROJECT_URL}/${SUBMODULE}, rather than relying on information from .gitmodules.
For a local URL/path to a super-project, git rev-parse --is-bare-repository is used to detect whether the super-project is bare or not.
For a remote URL to a super-project, the ending of the URL determines whether a bare or non-bare repository is assumed:
  • If the remote URL ends with /.git, a non-bare repository is assumed.
  • If the remote URL does NOT end with /.git, a bare repository is assumed.
Array/List:
Nested object
url
Specify the URL or path of the git repository. This uses the same syntax as your git clone command.
Type:String
name
ID of the repository, such as origin, to uniquely identify this repository among other remote repositories. This is the same "name" that you use in your git remote command. If left empty, Jenkins will generate unique names for you.

You normally want to specify this when you have multiple remote repositories.

Type:String
refspec
A refspec controls the remote refs to be retrieved and how they map to local refs. If left blank, it will default to the normal behaviour of git fetch, which retrieves all the branch heads as remotes/REPOSITORYNAME/BRANCHNAME. This default behaviour is OK for most cases.

In other words, the default refspec is "+refs/heads/*:refs/remotes/REPOSITORYNAME/*" where REPOSITORYNAME is the value you specify in the above "name of repository" textbox.

When do you want to modify this value? A good example is when you want to just retrieve one branch. For example, +refs/heads/master:refs/remotes/origin/master would only retrieve the master branch and nothing else.

The plugin uses a default refspec for its initial fetch, unless the "Advanced Clone Option" is set to honor refspec. This keeps compatibility with previous behavior, and allows the job definition to decide if the refspec should be honored on initial clone.

Multiple refspecs can be entered by separating them with a space character. +refs/heads/master:refs/remotes/origin/master +refs/heads/develop:refs/remotes/origin/develop retrieves the master branch and the develop branch and nothing else.

See the refspec definition in Git user manual for more details.

Type:String
credentialsId
Credential used to check out sources.
Type:String
branches
List of branches to build. Jenkins jobs are most effective when each job builds only a single branch. When a single job builds multiple branches, the changelog comparisons between branches often show no changes or incorrect changes.
Array/List:
Nested object
name

Specify the branches if you'd like to track a specific branch in a repository. If left blank, all branches will be examined for changes and built.

The safest way is to use the refs/heads/<branchName> syntax. This way the expected branch is unambiguous.

If your branch name has a / in it make sure to use the full reference above. When not presented with a full path the plugin will only use the part of the string right of the last slash. Meaning foo/bar will actually match bar.

If you use a wildcard branch specifier, with a slash (e.g. release/), you'll need to specify the origin repository in the branch names to make sure changes are picked up. So e.g. origin/release/

Possible options:

  • <branchName>
    Tracks/checks out the specified branch. If ambiguous the first result is taken, which is not necessarily the expected one. Better use refs/heads/<branchName>.
    E.g. master, feature1, ...
  • refs/heads/<branchName>
    Tracks/checks out the specified branch.
    E.g. refs/heads/master, refs/heads/feature1/master, ...
  • <remoteRepoName>/<branchName>
    Tracks/checks out the specified branch. If ambiguous the first result is taken, which is not necessarily the expected one.
    Better use refs/heads/<branchName>.
    E.g. origin/master
  • remotes/<remoteRepoName>/<branchName>
    Tracks/checks out the specified branch.
    E.g. remotes/origin/master
  • refs/remotes/<remoteRepoName>/<branchName>
    Tracks/checks out the specified branch.
    E.g. refs/remotes/origin/master
  • <tagName>
    This does not work since the tag will not be recognized as tag.
    Use refs/tags/<tagName> instead.
    E.g. git-2.3.0
  • refs/tags/<tagName>
    Tracks/checks out the specified tag.
    E.g. refs/tags/git-2.3.0
  • <commitId>
    Checks out the specified commit.
    E.g. 5062ac843f2b947733e6a3b105977056821bd352, 5062ac84, ...
  • ${ENV_VARIABLE}
    It is also possible to use environment variables. In this case the variables are evaluated and the result is used as described above.
    E.g. ${TREEISH}, refs/tags/${TAGNAME}, ...
  • <Wildcards>
    The syntax is of the form: REPOSITORYNAME/BRANCH. In addition, BRANCH is recognized as a shorthand of */BRANCH, '*' is recognized as a wildcard, and '**' is recognized as wildcard that includes the separator '/'. Therefore, origin/branches* would match origin/branches-foo but not origin/branches/foo, while origin/branches** would match both origin/branches-foo and origin/branches/foo.
  • :<regular expression>
    The syntax is of the form: :regexp. Regular expression syntax in branches to build will only build those branches whose names match the regular expression.
    Examples:
    • :^(?!(origin/prefix)).*
      • matches: origin or origin/master or origin/feature
      • does not match: origin/prefix or origin/prefix_123 or origin/prefix-abc
    • :origin/release-\d{8}
      • matches: origin/release-20150101
      • does not match: origin/release-2015010 or origin/release-201501011 or origin/release-20150101-something
    • :^(?!origin/master$|origin/develop$).*
      • matches: origin/branch1 or origin/branch-2 or origin/master123 or origin/develop-123
      • does not match: origin/master or origin/develop

Type:String
browser
Defines the repository browser that displays changes detected by the git plugin.
Nested choice of objects
$class: 'AssemblaWeb'
repoUrl
Specify the root URL serving this repository (such as https://www.assembla.com/code/PROJECT/git/).
Type:String
bitbucketServer
repoUrl
Specify the Bitbucket Server root URL for this repository (such as https://bitbucket:7990/OWNER/REPO/).
Type:String
$class: 'BitbucketWeb'
repoUrl
Specify the root URL serving this repository (such as https://bitbucket.org/OWNER/REPO/).
Type:String
$class: 'CGit'
repoUrl
Specify the root URL serving this repository (such as http://cgit.example.com:port/group/REPO/).
Type:String
$class: 'FisheyeGitRepositoryBrowser'
repoUrl
Specify the URL of this repository in FishEye (such as http://fisheye6.cenqua.com/browse/ant/).
Type:String
$class: 'GitBlitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository.
Type:String
projectName
Specify the name of the project in GitBlit.
Type:String
$class: 'GitLab'
repoUrl
Specify the root URL serving this repository (such as http://gitlabserver:port/group/REPO/).
Type:String
version (optional)
Specify the major and minor version of GitLab you use (such as 9.1). If you don't specify a version, a modern version of GitLab (>= 8.0) is assumed.
Type:String
$class: 'GitList'
repoUrl
Specify the root URL serving this repository (such as http://gitlistserver:port/REPO/).
Type:String
$class: 'GitWeb'
repoUrl
Specify the root URL serving this repository (such as https://github.com/jenkinsci/jenkins.git).
Type:String
$class: 'GithubWeb'
repoUrl
Specify the HTTP URL for this repository's GitHub page (such as https://github.com/jquery/jquery).
Type:String
$class: 'Gitiles'
repoUrl
Specify the root URL serving this repository (such as https://gwt.googlesource.com/gwt/).
Type:String
$class: 'GitoriousWeb'
repoUrl
Specify the root URL serving this repository (such as https://gitorious.org/gitorious/mainline).
Type:String
$class: 'GogsGit'
repoUrl
Specify the root URL serving this repository (such as http://gogs.example.com:port/username/some-repo-url.git).
Type:String
$class: 'KilnGit'
repoUrl
Specify the root URL serving this repository (such as https://khanacademy.kilnhg.com/Code/Website/Group/webapp).
Type:String
$class: 'Phabricator'
repoUrl
Specify the phabricator instance root URL (such as http://phabricator.example.com).
Type:String
repo
Specify the repository name in phabricator (such as the foo part of phabricator.example.com/diffusion/foo/browse).
Type:String
$class: 'RedmineWeb'
repoUrl
Specify the root URL serving this repository (such as http://SERVER/PATH/projects/PROJECT/repository).
Type:String
$class: 'RhodeCode'
repoUrl
Specify the HTTP URL for this repository's RhodeCode page (such as http://rhodecode.mydomain.com:5000/projects/PROJECT/repos/REPO/).
Type:String
$class: 'ScmManagerGitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository (such as https://scm-manager.org/scm/repo/namespace/name).
Type:String
$class: 'Stash'
repoUrl
Specify the HTTP URL for this repository's Stash page (such as http://stash.mydomain.com:7990/projects/PROJECT/repos/REPO/).
Type:String
$class: 'TFS2013GitRepositoryBrowser'
repoUrl
Either the name of the remote whose URL should be used, or the URL of this module in TFS (such as http://fisheye6.cenqua.com/tfs/PROJECT/_git/REPO/). If empty (default), the URL of the "origin" repository is used.

If TFS is also used as the repository server, this can usually be left blank.

Type:String
$class: 'ViewGitWeb'
repoUrl
Specify the root URL serving this repository (such as http://code.fealdia.org/viewgit/).
Type:String
projectName
Specify the name of the project in ViewGit (e.g. scripts, scuttle etc. from http://code.fealdia.org/viewgit/).
Type:String
gitTool

Absolute path to the git executable.

This is different from other Jenkins tool definitions. Rather than providing the directory that contains the executable, you must provide the complete path to the executable. Setting '/usr/bin/git' would be correct, while setting '/usr/bin/' is not correct.

Type:String
extensions

Extensions add new behavior or modify existing plugin behavior for different uses. Extensions help users more precisely tune plugin behavior to meet their needs.

Extensions include:

  • Clone extensions modify the git operations that retrieve remote changes into the agent workspace. The extensions can adjust the amount of history retrieved, how long the retrieval is allowed to run, and other retrieval details.
  • Checkout extensions modify the git operations that place files in the workspace from the git repository on the agent. The extensions can adjust the maximum duration of the checkout operation, the use and behavior of git submodules, the location of the workspace on the disc, and more.
  • Changelog extensions adapt the source code difference calculations for different cases.
  • Tagging extensions allow the plugin to apply tags in the current workspace.
  • Build initiation extensions control the conditions that start a build. They can ignore notifications of a change or force a deeper evaluation of the commits when polling.
  • Merge extensions can optionally merge changes from other branches into the current branch of the agent workspace. They control the source branch for the merge and the options applied to the merge.

Array/List:
Nested choice of objects
$class: 'AuthorInChangelog'
The default behavior is to use the Git commit's "Committer" value in Jenkins' build changesets. If this option is selected, the Git commit's "Author" value would be used instead.
$class: 'BuildChooserSetting'
When you are interested in using a job to build multiple heads (most typically multiple branches), you can choose how Jenkins choose what branches to build in what order.

This extension point in Jenkins is used by many other plugins to control the job to build specific commits. When you activate those plugins, you may see them installing a custom strategy here.

buildChooser
Nested choice of objects
$class: 'AncestryBuildChooser'
maximumAgeInDays
Type:int
ancestorCommitSha1
Type:String
$class: 'DefaultBuildChooser'
$class: 'InverseBuildChooser'
$class: 'BuildSingleRevisionOnly'
Disable scheduling for multiple candidate revisions.
If we have 3 branches:
----A--.---.--- B
         \-----C
jenkins would try to build (B) and (C).
This behaviour disables this and only builds one of them.
It is helpful to reduce the load of the Jenkins infrastructure when the SCM system like Bitbucket or GitHub should decide what commits to build.
$class: 'ChangelogToBranch'
This method calculates the changelog against the specified branch.
options
Nested object
compareRemote
Name of the repository, such as origin, that contains the branch you specify below.
Type:String
compareTarget
The name of the branch within the named repository to compare against.
Type:String
$class: 'CheckoutOption'
timeout
Specify a timeout (in minutes) for checkout.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
$class: 'CleanBeforeCheckout'
Clean up the workspace before every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CleanCheckout'
Clean up the workspace after every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CloneOption'
shallow
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
noTags
Deselect this to perform a clone without tags, saving time and disk space when you just want to access what is specified by the refspec.
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
Type:String
timeout
Specify a timeout (in minutes) for clone and fetch operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
honorRefspec (optional)
Perform initial clone using the refspec defined for the repository. This can save time, data transfer and disk space when you only need to access the references specified by the refspec.
Type:boolean
$class: 'DisableRemotePoll'
Git plugin uses git ls-remote polling mechanism by default when configured with a single branch (no wildcards!). This compare the latest built commit SHA with the remote branch without cloning a local copy of the repo.

If you don't want to / can't use this.

If this option is selected, polling will require a workspace and might trigger unwanted builds (see JENKINS-10131).
$class: 'GitLFSPull'
Enable git large file support for the workspace by pulling large files after the checkout completes. Requires that the controller and each agent performing an LFS checkout have installed `git lfs`.
$class: 'IgnoreNotifyCommit'
If checked, this repository will be ignored when the notifyCommit-URL is accessed regardless of if the repository matches or not.
$class: 'LocalBranch'
If given, checkout the revision to build as HEAD on this branch.

If selected, and its value is an empty string or "**", then the branch name is computed from the remote branch without the origin. In that case, a remote branch origin/master will be checked out to a local branch named master, and a remote branch origin/develop/new-feature will be checked out to a local branch named develop/newfeature.

Please note that this has not been tested with submodules.

localBranch
Type:String
$class: 'MessageExclusion'
excludedMessage
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions committed with message matched to Pattern when determining if a build needs to be triggered. This can be used to exclude commits done by the build itself from triggering another build, assuming the build server commits the change with a distinct message.

Exclusion uses Pattern matching

.*\[maven-release-plugin\].*
The example above illustrates that if only revisions with "[maven-release-plugin]" message in first comment line have been committed to the SCM a build will not occur.

You can create more complex patterns using embedded flag expressions.

(?s).*FOO.*
This example will search FOO message in all comment lines.
Type:String
$class: 'PathRestriction'
If set, and Jenkins is set to poll for changes, Jenkins will pay attention to included and/or excluded files and/or folders when determining if a build needs to be triggered.

Using this behaviour will preclude the faster git ls-remote polling mechanism, forcing polling to require a workspace thus sometimes triggering unwanted builds, as if you had selected the Force polling using workspace extension as well.

includedRegions
Each inclusion uses java regular expression pattern matching, and must be separated by a new line. An empty list implies that everything is included.

    myapp/src/main/web/.*\.html
    myapp/src/main/web/.*\.jpeg
    myapp/src/main/web/.*\.gif
  
The example above illustrates that a build will only occur, if html/jpeg/gif files have been committed to the SCM. Exclusions take precedence over inclusions, if there is an overlap between included and excluded regions.
Type:String
excludedRegions
Each exclusion uses java regular expression pattern matching, and must be separated by a new line.

    myapp/src/main/web/.*\.html
    myapp/src/main/web/.*\.jpeg
    myapp/src/main/web/.*\.gif
  
The example above illustrates that if only html/jpeg/gif files have been committed to the SCM a build will not occur.
Type:String
$class: 'PerBuildTag'
Create a tag in the workspace for every build to unambiguously mark the commit that was built. You can combine this with Git publisher to push the tags to the remote repository.
$class: 'PreBuildMerge'
These options allow you to perform a merge to a particular branch before building. For example, you could specify an integration branch to be built, and to merge to master. In this scenario, on every change of integration, Jenkins will perform a merge with the master branch, and try to perform a build if the merge is successful. It then may push the merge back to the remote repository if the Git Push post-build action is selected.
options
Nested object
mergeTarget
The name of the branch within the named repository to merge to, such as master.
Type:String
fastForwardMode (optional)
Merge fast-forward mode selection.
The default, --ff, gracefully falls back to a merge commit when required.
For more information, see the Git Merge Documentation
Values:
FF
FF_ONLY
NO_FF
mergeRemote (optional)
Name of the repository, such as origin, that contains the branch you specify below. If left blank, it'll default to the name of the first repository configured above.
Type:String
mergeStrategy (optional)
Merge strategy selection. This feature is not fully implemented in JGIT.
Values:
DEFAULT
RESOLVE
RECURSIVE
OCTOPUS
OURS
SUBTREE
RECURSIVE_THEIRS
$class: 'PruneStaleBranch'
Run "git remote prune" for each remote, to prune obsolete local branches.
pruneTags
pruneTags
Type:boolean
$class: 'RelativeTargetDirectory'
relativeTargetDir
Specify a local directory (relative to the workspace root) where the Git repository will be checked out. If left empty, the workspace root itself will be used.

This extension should not be used in Jenkins Pipeline (either declarative or scripted). Jenkins Pipeline already provides standard techniques for checkout to a subdirectory. Use ws and dir in Jenkins Pipeline rather than this extension.

Type:String
$class: 'ScmName'

Unique name for this SCM. Needed when using Git within the Multi SCM plugin.

name
Type:String
$class: 'SparseCheckoutPaths'

Specify the paths that you'd like to sparse checkout. This may be used for saving space (Think about a reference repository). Be sure to use a recent version of Git, at least above 1.7.10

sparseCheckoutPaths
Array/List:
Nested object
path
Type:String
$class: 'SubmoduleOption'
disableSubmodules
By disabling support for submodules you can still keep using basic git plugin functionality and just have Jenkins to ignore submodules completely as if they didn't exist.
Type:boolean
recursiveSubmodules
Retrieve all submodules recursively (uses '--recursive' option which requires git>=1.6.5)
Type:boolean
trackingSubmodules
Retrieve the tip of the configured branch in .gitmodules (Uses '--remote' option which requires git>=1.8.2)
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
To prepare a reference folder with multiple subprojects, create a bare git repository and add all the remote urls then perform a fetch:
  git init --bare
  git remote add SubProject1 https://gitrepo.com/subproject1
  git remote add SubProject2 https://gitrepo.com/subproject2
  git fetch --all
  
Type:String
timeout
Specify a timeout (in minutes) for submodules operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
parentCredentials
Use credentials from the default remote of the parent project.
Type:boolean
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
shallow (optional)
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
threads (optional)
Specify the number of threads that will be used to update submodules.
If unspecified, the command line git default thread count is used.
Type:int
$class: 'UserExclusion'
excludedUsers
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions committed by users in this list when determining if a build needs to be triggered. This can be used to exclude commits done by the build itself from triggering another build, assuming the build server commits the change with a distinct SCM user.

Using this behaviour will preclude the faster git ls-remote polling mechanism, forcing polling to require a workspace thus sometimes triggering unwanted builds, as if you had selected the Force polling using workspace extension as well.

Each exclusion uses exact string comparison and must be separated by a new line. User names are only excluded if they exactly match one of the names in this list.

auto_build_user
The example above illustrates that if only revisions by "auto_build_user" have been committed to the SCM a build will not occur.
Type:String
$class: 'UserIdentity'
name

If given, "GIT_COMMITTER_NAME=[this]" and "GIT_AUTHOR_NAME=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
email

If given, "GIT_COMMITTER_EMAIL=[this]" and "GIT_AUTHOR_EMAIL=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
$class: 'WipeWorkspace'
Delete the contents of the workspace before building, ensuring a fully fresh workspace.
doGenerateSubmoduleConfigurations (optional)

Removed facility that was intended to test combinations of git submodule versions. Removed in git plugin 4.6.0. Ignores the user provided value and always uses false as its value.

Type:boolean
submoduleCfg (optional)

Removed facility that was intended to test combinations of git submodule versions. Removed in git plugin 4.6.0. Ignores the user provided value(s) and always uses empty values.

Array/List:
Nested object
submoduleName

Removed in git plugin 4.6.0.

Type:String
branches

Removed in git plugin 4.6.0.

Array/List:
Type:String
$class: 'MercurialSCM'
source
Specify the repository to track. This can be URL or a local file path. If you are specifying HTTP credentials, do not include a username in the URL.
Type:String
browser (optional)
Nested choice of objects
$class: 'FishEye'
url
Specify the root URL serving this repository, such as: http://www.example.org/browse/hg/
Type:String
$class: 'GoogleCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'HgWeb'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'Kallithea'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'KilnHG'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCodeLegacy'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'ScmManager'
url
Specify the root URL serving this repository (such as http://YOURSCMMANAGER/scm/repo/NAMESPACE/NAME/).
Type:String
clean (optional)
When this option is checked, each build will wipe any local modifications or untracked files in the repository checkout. This is often a convenient way to ensure that a build is not using any artifacts from earlier builds.
Type:boolean
credentialsId (optional)
Optional credentials to use when cloning or pulling from the remote repository. Supports username/password with HTTP(S) URLs, and SSH private key with SSH URLs.
Type:String
disableChangeLog (optional)
When checked, Hudson will not calculate the Mercurial changelog for each build. Disabling the changelog can decrease the amount of time needed to update a very large repository.
Type:boolean
installation (optional)
Type:String
modules (optional)
Reduce unnecessary builds by specifying a comma or space delimited list of "modules" within the repository. A module is a directory name within the repository that this project lives in. If this field is set, changes outside the specified modules will not trigger a build (even though the whole repository is checked out anyway due to the Mercurial limitation.)
Type:String
revision (optional)
Specify the branch or tag name you would like to track. (If you do not type anything, the default value is the default branch.)
Type:String
revisionType (optional)
Specify the kind of revision you expect Jenkins to update your working copy to.
Values:
BRANCH
TAG
CHANGESET
REVSET
subdir (optional)
If not empty, check out the Mercurial repository into this subdirectory of the job's workspace. For example: my/sources (use forward slashes). If changing this entry, you probably want to clean the workspace first.
Type:String
none
$class: 'SubversionSCM'
Checks out the source code from Subversion repositories. See post-commit hook set up for improved turn-around time and performance in polling.
locations
Array/List:
Nested object
remote
Type:String
credentialsId
Type:String
local
Specify a local directory (relative to the workspace root) where this module is checked out. If left empty, the last path component of the URL is used as the default, just like the svn CLI. A single period (.) may be used to check out the project directly into the workspace rather than into a subdirectory.
Type:String
depthOption
--depth option for checkout and update commands. Default value is infinity.
  • empty includes only the immediate target of the operation, not any of its file or directory children.
  • files includes the immediate target of the operation and any of its immediate file children.
  • immediates includes the immediate target of the operation and any of its immediate file or directory children. The directory children will themselves be empty.
  • infinity includes the immediate target, its file and directory children, its children's children, and so on to full recursion.
  • as-it-is takes the working depth from the current working copy, allows for setting update depth manually using --set-depth option.
More information can be found here.
Type:String
ignoreExternalsOption
"--ignore-externals" option will be used with svn checkout, svn update commands to disable externals definition processing.

More information can be found here.
Note: there is the potential to leverage svn:externals to gain read access to the entire Subversion repository. This can happen if you follow the normal practice of giving Jenkins credentials with read access to the entire Subversion repository. You will also need to provide the credentials to use when checking/polling out the svn:externals using the Additional Credentials option.

Type:boolean
cancelProcessOnExternalsFail
Determines if the process should be cancelled when checkout/update svn:externals failed. Will work when "Ignore externals" box is not checked. Default choice is to cancelled the process when checkout/update svn:externals failed.
Type:boolean
workspaceUpdater
Nested choice of objects
$class: 'CheckoutUpdater'
$class: 'NoopUpdater'
$class: 'UpdateUpdater'
$class: 'UpdateWithCleanUpdater'
$class: 'UpdateWithRevertUpdater'
browser
Nested choice of objects
$class: 'Assembla'
spaceName
Type:String
$class: 'CollabNetSVN'
url
The repository browser URL for the root of the project. For example, a Java.net project called myproject would use https://myproject.dev.java.net/source/browse/myproject.
Type:String
$class: 'FishEyeSVN'
url
Specify the URL of this module in FishEye. (such as http://fisheye6.cenqua.com/browse/ant/)
Type:String
rootModule
Specify the root Subversion module that this FishEye monitors. For example, for http://fisheye6.cenqua.com/browse/ant/, this field would be ant because it displays the directory "/ant" of the ASF repo. If FishEye is configured to display the whole SVN repository, leave this field empty.
Type:String
svnPhabricator
url
Type:String
repo
Type:String
$class: 'SVNWeb'
url
Type:String
$class: 'ScmManagerSvnRepositoryBrowser'
repoUrl
Specify the root URL serving this repository (such as https://scm-manager.org/scm/repo/namespace/name).
Type:String
$class: 'Sventon'
url
Specify the URL of the Sventon repository browser. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be http://somehost.com/svn/
Type:String
repositoryInstance
Specify the Sventon repository instance name that references this subversion repository. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be local
Type:String
$class: 'Sventon2'
url
Specify the URL of the Sventon repository browser. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be http://somehost.com/svn/
Type:String
repositoryInstance
Specify the Sventon repository instance name that references this subversion repository. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be local
Type:String
$class: 'ViewSVN'
url
Specify the root URL of ViewSVN for this repository (such as this).
Type:String
$class: 'VisualSVN'
url
Specify the root URL of VisualSVN for this repository (such as https://demo-server.visualsvn.com/!/#tortoisesvn).
Type:String
$class: 'WebSVN'
url
Type:String
excludedRegions
If set, and Jenkins is set to poll for changes, Jenkins will ignore any files and/or folders in this list when determining if a build needs to be triggered.

Each exclusion uses regular expression pattern matching, and must be separated by a new line.

	/trunk/myapp/src/main/web/.*\.html
	/trunk/myapp/src/main/web/.*\.jpeg
	/trunk/myapp/src/main/web/.*\.gif
  
The example above illustrates that if only html/jpeg/gif files have been committed to the SCM a build will not occur.

More information on regular expressions can be found here.

Type:String
excludedUsers
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions committed by users in this list when determining if a build needs to be triggered. This can be used to exclude commits done by the build itself from triggering another build, assuming the build server commits the change with a distinct SCM user.

Each exclusion uses literal pattern matching, and must be separated by a new line.

	 auto_build_user
  
The example above illustrates that if only revisions by "auto_build_user" have been committed to the SCM a build will not occur.
Type:String
excludedRevprop
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions that are marked with the given revision property (revprop) when determining if a build needs to be triggered. This can be used to exclude commits done by the build itself from triggering another build, assuming the build server commits the change with the correct revprop.

This type of exclusion only works with Subversion 1.5 servers and newer.

More information on revision properties can be found here.

Type:String
excludedCommitMessages
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions with commit messages containing any of the given regular expressions when determining if a build needs to be triggered.
Type:String
includedRegions
If set, and Jenkins is set to poll for changes, Jenkins will ignore any files and/or folders that are not in this list when determining if a build needs to be triggered.

Each inclusion uses regular expression pattern matching, and must be separated by a new line.

This is useful when you need to check out an entire resource for building, but only want to do the build when a subset has changed.

	/trunk/myapp/c/library1/.*
	/trunk/myapp/c/library2/.*
  
If /trunk/myapp is checked out, the build will only occur when there are changes to either the c/library1 and c/library2 subtrees.

If there are also excluded regions specified, then a file is not ignored when it is in the included list and not in the excluded list.

More information on regular expressions can be found here.

Type:String
ignoreDirPropChanges
If set, Jenkins ignores svn-property only changes of directories. These changes are ignored when determining whether a build should be triggered and are removed from a build's changeset. Main usage of this property is to ignore svn:mergeinfo changes (which would otherwise e.g. lead to a complete rebuild of a maven project, in spite of incremental build option).
Type:boolean
filterChangelog
If set Jenkins will apply the same inclusion and exclusion patterns for displaying changelog entries as it does for polling for changes. If this is disabled, changes which are excluded for polling are still displayed in the changelog.
Type:boolean
additionalCredentials

If there are additional credentials required in order to obtain a complete checkout of the source, they can be provided here.

The realm is how the repository self-identifies to a client. It usually has the following format:

<proto://host:port> Realm Name

  • proto is the protocol, e.g. http or svn.
  • host is the host how it's accessed by Jenkins, e.g. as IP address 192.168.1.100, host name svnserver, or host name and domain svn.example.org.
  • port is the port, even if not explicitly specified. By default, this is 80 for HTTP, 443 for HTTPS, 3690 for the svn protocol.
  • Realm Name is how the repository self-identifies. Common options include VisualSVN Server, Subversion Authentication or the UUID of the repository.

To find out the realm, you could do any of the following:

  • If you access the repository via HTTP or HTTPS: Open the repo in a web browser without saved credentials. It will use the Realm Name (see above) in the authentication dialog.
  • Use the command line svn program.
    • If you don't have stored the credentials, run e.g. svn info https://svnserver/repo and it will tell you the realm when asking you to enter a password, e.g.: Authentication realm: <svn://svnserver:3690> VisualSVN Server.
    • If you have already stored the credentials to access the repository, look for the realm name in one of the files in ~/.subversion/auth/svn/simple; it will be two lines below the line svn:realmstring.
  • When accessing a repository via the svn+ssh protocol, the realm has the format username@svn+ssh://host:port – note that the username is before the svn+ssh:// (unlike the URL used for normal SVN operations), and that there are no angle brackets and no realm name. For this protocol the default port is 22.

Make sure to enter the realm exactly as shown, starting with a < (except for repositories accessed via svn+ssh – see above).

Array/List:
Nested object
realm
This is the realm that the SvnKit library associates with a specific checkout. For most Subversion servers this will typically be of the format <scheme://hostname(:port)> name, while for servers accessed via svn+ssh it is of the format (username@)svn+ssh://hostname(:port).
Type:String
credentialsId
Select the credential from the list of relevant credentials in order to use that credential for checking out the source code.
Type:String
quietOperation

Mimics subversion command line --quiet parameter for check out / update operations to help keep the output shorter. Prints nothing, or only summary information.

Type:boolean
changelog (optional)
Enable or Disable 'Include in changelog':

If 'Include in changelog' is enabled for an SCM source, then when a build occurs, the changes from that SCM source will be included in the changelog.

If 'Include in changelog' is disabled, then when a build occurs, the changes from this SCM source will not be included in the changelog.

Type:boolean
poll (optional)
Enable or Disable 'Include in polling'

If 'Include in polling' is enabled or 'Include in changelog' is enabled, then when polling occurs, the job will be started if changes are detected from this SCM source.

If 'Include in polling' is disabled and 'Include in changelog' is disabled, then when polling occurs, changes that are detected from this repository will be ignored.

Type:boolean
compareVersions: Compare two version number strings

Compare two version numbers with each other. See VersionNumber.java for how version strings are handled.

The return value is an Integer;

  • -1 if v1 < v2
  • 0 if v1 == v2
  • 1 if v1 > v2

v1

The version number string that will be compared to v2.

Type:String
v2

The version number string that v1 will be compared to.

Type:String
failIfEmpty (optional)

Fail the build if v1 or v2 is empty or null.

By default the empty string or null is treated as the lowest version and will not fail the build. I.e.:

  • null compared to null == 0
  • empty compared to empty == 0
  • null compared to empty == 0
  • null or empty compared to anything == -1
  • anything compared to null or empty == 1

Type:boolean
configFileProvider: Provide Configuration files
Make globally configured files available in your local workspace. All files configured via the config-file-provider plugin are available and can be referenced.
managedFiles
Array/List:
configFile
fileId

Name of the file.

Type:String
replaceTokens (optional)

Decides whether the token should be replaced using macro.

Type:boolean
targetLocation (optional)

Name of the file (with optional file relative to workspace directory) where the config file should be copied.

Type:String
variable (optional)

Name of the variable which can be used as the reference for further configuration.

Type:String
container: Run build steps in a container
Selects a container of the agent pod so that all shell steps are executed in that container.
name
Type:String
shell (optional)

Specifies a shell which will run inside the container and process requests from Jenkins to run executables, set environment variables, and similar infrastructure.

This does not affect the shell used to run user code, such as sh steps. To run your scripts with a specific shell on Linux, use an interpreter line:

sh '''#!/bin/bash
for x in {0..9}; do echo x; done
'''

or just use a subprocess and an externally versioned script:

sh 'bash ci.sh'

On Windows, choose between the bat or powershell steps.

For a pod running on Linux, defaults to sh, which should be in $PATH; for a pod running on Windows, defaults to cmd, which should be in %Path%. Should not generally be overridden.

Type:String
createTag: Create Tag (Nexus Repository Manager 3.x)
nexusInstanceId
Type:String
tagName
Tag name is required and must be unique. Name can only contain letters, numbers, underscores, hyphens and dots and cannot start with an underscore or dot. The name cannot exceed 256 characters
Type:String
tagAttributesJson (optional)
Optional metadata for the tag in JSON format. These attributes will be merged with those contained in the attributes file if both are provided. Attributes in this field will override those present in the file
Type:String
tagAttributesPath (optional)
The file path (environment-aware) to the optional metadata for the tag, using the workspace as the base path
Type:String
deleteComponents: Delete Components (Nexus Repository Manager 3.x)
nexusInstanceId
Type:String
tagName
Components associated with this tag will be deleted
Type:String
deleteDir: Recursively delete the current directory from the workspace
Recursively deletes the current directory and its contents. Symbolic links and junctions will not be followed but will be removed. To delete a specific directory of a workspace wrap the deleteDir step in a dir step.
dependencyCheck: Invoke Dependency-Check
additionalArguments (optional)
Type:String
odcInstallation (optional)
Type:String
skipOnScmChange (optional)
Type:boolean
skipOnUpstreamChange (optional)
Type:boolean
dependencyCheckPublisher: Publish Dependency-Check results
failedNewCritical (optional)
Type:int
failedNewHigh (optional)
Type:int
failedNewLow (optional)
Type:int
failedNewMedium (optional)
Type:int
failedTotalCritical (optional)
Type:int
failedTotalHigh (optional)
Type:int
failedTotalLow (optional)
Type:int
failedTotalMedium (optional)
Type:int
newThresholdAnalysisExploitable (optional)
Type:boolean
pattern (optional)
Type:String
totalThresholdAnalysisExploitable (optional)
Type:boolean
unstableNewCritical (optional)
Type:int
unstableNewHigh (optional)
Type:int
unstableNewLow (optional)
Type:int
unstableNewMedium (optional)
Type:int
unstableTotalCritical (optional)
Type:int
unstableTotalHigh (optional)
Type:int
unstableTotalLow (optional)
Type:int
unstableTotalMedium (optional)
Type:int
dependencyTrackPublisher: Publish BOM to Dependency-Track
artifact
Specifies the artifact to upload. Dependency-Track supports uploading of CycloneDX bill-of-materials (BOM) formats.

See Best Practices for additional information.

The value can contain environment variables in the form of ${VARIABLE_NAME} which are resolved.

Type:String
synchronous

Synchronous publishing mode uploads a BOM to Dependency-Track and waits for Dependency-Track to process and return results. The results returned are identical to the auditable findings but exclude findings that have previously been suppressed. Analysis decisions and vulnerability details are included in the response.

This feature provides per-build results that display all finding details as well as interactive charts that display trending information.

Synchronous mode is possible with Dependency-Track v3.3.1 and higher.

The API key provided requires the VIEW_VULNERABILITY permission to use this feature with Dependency-Track v4.4 and newer!

Type:boolean
autoCreateProjects (optional)
Enable auto creation of projects when authentication is enabled on Dependency-Track and the API key provided has the PROJECT_CREATION_UPLOAD permission.
Type:boolean
dependencyTrackApiKey (optional)
When authentication is enabled on Dependency-Track, a valid API key will be required.
Type:String
dependencyTrackFrontendUrl (optional)
The alternative base URL to the Frontend of Dependency-Track v3 or higher. (i.e. http://hostname:port)

Use this if you run backend and frontend on different servers. If omitted, "Dependency-Track Backend URL" will be used instead.

Type:String
dependencyTrackUrl (optional)
The base URL to Dependency-Track Backend (i.e. http://hostname:port)
Type:String
failedNewCritical (optional)
Type:int
failedNewHigh (optional)
Type:int
failedNewLow (optional)
Type:int
failedNewMedium (optional)
Type:int
failedTotalCritical (optional)
Type:int
failedTotalHigh (optional)
Type:int
failedTotalLow (optional)
Type:int
failedTotalMedium (optional)
Type:int
overrideGlobals (optional)
Allows to override global settings for "Auto Create Projects", "Dependency-Track URL", "Dependency-Track Frontend URL" and "API key".

Can be ignored in pipelines, just set the properties dependencyTrackUrl, dependencyTrackFrontendUrl, dependencyTrackApiKey and autoCreateProjects as needed.

Type:boolean
projectId (optional)
Specifies the unique Project ID of the project to upload scan results to. The Project ID is a UUID with the following format: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx

If the list of projects are not displayed (such as an HTTP 403 response), ensure the API key specified in the global configuration has VIEW_PORTFOLIO permission in addition to BOM_UPLOAD and/or SCAN_UPLOAD. Permissions are defined in Dependency-Track.

Type:String
projectName (optional)
Specifies the name of the project for automatic creation of project during the upload process.

This is an alternative to specifying the unique UUID. It must be used together with a project version.

Ensure the API key specified in the global configuration has PROJECT_CREATION_UPLOAD permission and that you have enabled Auto Create Projects.

The value can contain environment variables in the form of ${VARIABLE_NAME} which are resolved.

Type:String
projectProperties (optional)
Set additional properties for the given project.

The API key provided requires the PORTFOLIO_MANAGEMENT permission to use this feature!

Nested object
description (optional)
The description to be set for the project.
Type:String
group (optional)
Specifies the value of "Namespace / Group / Vendor" to be set for the project.
Type:String
swidTagId (optional)
Specifies the SWID Tag ID to be set for the project.
Type:String
tags (optional)
Specifies the list of tags to be set for the project. Separate multiple tags with spaces or put each tag on a separate line.

All tags are automatically lowercased!

Nested choice of objects
(not enumerable)
projectVersion (optional)
Specifies the version of the project for automatic creation of project during the upload process.

This is an alternative to specifying the unique UUID. It must be used together with a project name.

Ensure the API key specified in the global configuration has PROJECT_CREATION_UPLOAD permission and that you have enabled Auto Create Projects.

The value can contain environment variables in the form of ${VARIABLE_NAME} which are resolved.

Type:String
unstableNewCritical (optional)
Type:int
unstableNewHigh (optional)
Type:int
unstableNewLow (optional)
Type:int
unstableNewMedium (optional)
Type:int
unstableTotalCritical (optional)
Type:int
unstableTotalHigh (optional)
Type:int
unstableTotalLow (optional)
Type:int
unstableTotalMedium (optional)
Type:int
dir: Change current directory
Change current directory. Any step inside the dir block will use this directory as current and any relative path will use it as base path.
path
The relative path of the directory in the workspace to use as a new working directory.
Type:String
discoverReferenceBuild: Discover reference build
referenceJob (optional)
The reference job is the baseline that is used to determine which of the issues in the current build are new, outstanding, or fixed. This baseline is also used to determine the number of new issues for the quality gate evaluation.
Type:String
echo: Print Message
message
The message to write to the console output.
Type:String
error: Error signal
Signals an error. Useful if you want to conditionally abort some part of your program. You can also just throw new Exception(), but this step will avoid printing a stack trace.
message
The message that will be logged to the console when an error is caught.
Type:String
fileExists: Verify if file exists in workspace
Checks if the given file exists on the current node. Returns true | false. This step must be run inside a node context:

# Declarative Syntax
stage ('Check for existence of index.html') {
    agent any # Could be a top-level directive or a stage level directive
    steps {
        script {
            if (fileExists('src/main/rersources/index.html') {
                echo "File src/main/rersources/index.html found!"
            }
        }
    }
}

With the Declarative Syntax, it must be run in a stage with a defined agent (e.g. different than `agent none`):

# Scripted Syntax
node {
    if (fileExists('src/main/rersources/index.html') {
        echo "File src/main/rersources/index.html found!"
    }
}

file
Path to a file or a directory to verify its existence.
  • Both absolute and relative paths are supported. When using relative path, it is relative to the current working directory (by default: the workspace).
  • Both Unix and Windows path are supported using a
    /
    separator:

    node('Linux') {
        if (fileExists('/usr/local/bin/jenkins.sh') {
            sh '/usr/local/bin/jenkins.sh'
        }
    }
    node('Windows') {
        if (fileExists('C:/jenkins.exe') {
            bat 'C:/jenkins.exe'
        }
    }
    

    When using a Windows path with the backslash (
    \
    ) separator, do not forget to escape it:

    node('Windows') { if (fileExists('src\\main\\resources') { echo 'Found a directory resources.' } }

Type:String
findFiles: Find files in the workspace

Find files in the current working directory. The step returns an array of file info objects who's properties you can see in the below example.
Ex: def files = findFiles(glob: '**/TEST-*.xml') echo """${files[0].name} ${files[0].path} ${files[0].directory} ${files[0].length} ${files[0].lastModified}"""

excludes (optional)
Type:String
glob (optional)

Ant style pattern of file paths that should match. If this property is set all descendants of the current working directory will be searched for a match and returned, if it is omitted only the direct descendants of the directory will be returned.

Type:String
fingerprint: Record fingerprints of files to track usage
Jenkins can record the 'fingerprint' of files (most often jar files) to keep track of where/when those files are produced and used. When you have inter-dependent projects on Jenkins, this allows you to quickly find out answers to questions like:
  • I have foo.jar on my HDD but which build number of FOO did it come from?
  • My BAR project depends on foo.jar from the FOO project.
    • Which build of foo.jar is used in BAR #51?
    • Which build of BAR contains my bug fix to foo.jar #32?

To use this feature, all of the involved projects (not just the project in which a file is produced, but also the projects in which the file is used) need to use this and record fingerprints.

See this document for more details.

targets
Can use wildcards like module/dist/**/*.zip (see the @includes of Ant fileset for the exact format). The base directory is the workspace.
Type:String
caseSensitive (optional)
Fingerprinter uses Ant org.apache.tools.ant.DirectoryScanner which by default is case sensitive. For instance, if the job produces *.hpi files, pattern "**/*.HPI" will fail to find them.

This option can be used to disable case sensitivity. When it's unchecked, pattern "**/*.HPI" will match any *.hpi files, or pattern "**/cAsEsEnSiTiVe.jar" will match a file called caseSensitive.jar.
Type:boolean
defaultExcludes (optional)
Type:boolean
excludes (optional)
Optionally specify the 'excludes' pattern, such as "foo/bar/**/*". Use "," to set a list of patterns. A file that matches this mask will not be fingerprinted even if it matches the mask specified in 'files to fingerprint' section.
Type:String
git: Git

Git step. It performs a clone from the specified repository.

Use the Pipeline Syntax Snippet Generator to generate a sample pipeline script for the git step. More advanced checkout operations require the checkout step rather than the git step. Examples of the git step include:

See the argument descriptions for more details.

The git step is a simplified shorthand for a subset of the more powerful checkout step:

checkout([$class: 'GitSCM', branches: [[name: '*/master']],
    userRemoteConfigs: [[url: 'http://git-server/user/repository.git']]])


NOTE: The checkout step is the preferred SCM checkout method. It provides significantly more functionality than the git step.

Use the Pipeline Syntax Snippet Generator to generate a sample pipeline script for the checkout step.

The checkout step can be used in many cases where the git step cannot be used. Refer to the git plugin documentation for detailed descriptions of options available to the checkout step. For example, the git step does not support:

  • SHA-1 checkout
  • Tag checkout
  • Submodule checkout
  • Sparse checkout
  • Large file checkout (LFS)
  • Reference repositories
  • Branch merges
  • Repository tagging
  • Custom refspecs
  • Timeout configuration
  • Changelog calculation against a non-default reference
  • Stale branch pruning


Example: Git step with defaults

Checkout from the git plugin source repository using https protocol, no credentials, and the master branch.

The Pipeline Syntax Snippet Generator generates this example:

git 'https://github.com/jenkinsci/git-plugin'

Example: Git step with https and a specific branch

Checkout from the Jenkins source repository using https protocol, no credentials, and a specific branch (stable-2.204). Note that this must be a local branch name like 'master' or 'develop'.

Branch names that are not supported by the git step

  • Remote branch names like 'origin/master' and 'origin/develop' are not supported as the branch argument
  • SHA-1 hashes are not supported as the branch argument
  • Tag names are not supported as the branch argument

Remote branch names, SHA-1 hashes, and tag names are supported by the general purpose checkout step.

The Pipeline Syntax Snippet Generator generates this example:

git branch: 'stable-2.204',
    url: 'https://github.com/jenkinsci/jenkins.git'

Example: Git step with ssh and a private key credential

Checkout from the git client plugin source repository using ssh protocol, private key credentials, and the master branch. The credential must be a private key credential if the remote git repository is accessed with the ssh protocol. The credential must be a username / password credential if the remote git repository is accessed with http or https protocol.

The Pipeline Syntax Snippet Generator generates this example:

git credentialsId: 'my-private-key-credential-id',
    url: 'git@github.com:jenkinsci/git-client-plugin.git'

Example: Git step with https and changelog disabled

Checkout from the Jenkins source repository using https protocol, no credentials, the master branch, and changelog calculation disabled. If changelog is false, then the changelog will not be computed for this job. If changelog is true or is not set, then the changelog will be computed. See the workflow scm step documentation for more changelog details.

The Pipeline Syntax Snippet Generator generates this example:

git changelog: false,
    url: 'https://github.com/jenkinsci/credentials-plugin.git'

Example: Git step with https protocol and polling disabled

Checkout from the Jenkins platform labeler repository using https protocol, no credentials, the master branch, and no polling for changes. If poll is false, then the remote repository will not be polled for changes. If poll is true or is not set, then the remote repository will be polled for changes. See the workflow scm step documentation for more polling details.

The Pipeline Syntax Snippet Generator generates this example:

git poll: false,
    url: 'https://github.com/jenkinsci/platformlabeler-plugin.git'


Argument Descriptions
url

URL of the repository to be checked out in the workspace. Required parameter.

Repository URL's should follow the git URL guidelines. Git steps to access a secured repository should provide a Jenkins credential with the credentialsId argument rather than embedding credentials in the URL. Credentials embedded in a repository URL may be visible in console logs or in other log files.

Type:String
branch (optional)

Branch to be checked out in the workspace. Default is 'master'.

Note that this must be a local branch name like 'master' or 'develop'. Remote branch names like 'origin/master' and 'origin/develop' are not supported as the branch argument. Tag names are not supported as the branch argument. SHA-1 hashes are not supported as the branch argument. Remote branch names, tag names, and SHA-1 hashes are supported by the general purpose checkout step.

Type:String
changelog (optional)

Compute changelog for this job. Default is 'true'.

If changelog is false, then the changelog will not be computed for this job. If changelog is true or is not set, then the changelog will be computed.

Type:boolean
credentialsId (optional)

Identifier of the credential used to access the remote git repository. Default is '<empty>'.

The credential must be a private key credential if the remote git repository is accessed with the ssh protocol. The credential must be a username / password credential if the remote git repository is accessed with http or https protocol.

Type:String
poll (optional)

Poll remote repository for changes. Default is 'true'.

If poll is false, then the remote repository will not be polled for changes. If poll is true or is not set, then the remote repository will be polled for changes.

Type:boolean
googleStorageBucketLifecycle: Google Storage Bucket Lifecycle
credentialsId
Type:String
bucket
Type:String
ttl
Type:int
googleStorageBuildLogUpload: Google Storage Build Log Upload
credentialsId
Type:String
bucket
Type:String
logName
Type:String
pathPrefix (optional)
Type:String
sharedPublicly (optional)
Type:boolean
showInline (optional)
Type:boolean
googleStorageDownload: Google Storage Download
credentialsId
Type:String
bucketUri

This specifies the cloud object to download from Cloud Storage. You can view these by visiting the "Cloud Storage" section of the Cloud Console for your project.
A single asterisk can be specified in the object path (not the bucket name), past the last "/". The asterisk behaves consistently with gsutil. For example, gs://my-bucket-name/pre/a_*.txt would match the objects in cloud bucket my-bucket-name that are named pre/a_2.txt or pre/a_abc23-4.txt, but not pre/a_2/log.txt.

Type:String
localDirectory

The local directory that will store the downloaded files. The path specified is considered relative to the build's workspace. Example value:

  • path/to/dir
Type:String
pathPrefix (optional)

The specified prefix will be stripped from all downloaded filenames. Filenames that do not start with this prefix will not be modified. If this prefix does not have a trailing slash, it will be added automatically.

Type:String
googleStorageUpload: Google Storage Classic Upload
credentialsId
Type:String
bucket
Type:String
pattern
Type:String
pathPrefix (optional)
Type:String
sharedPublicly (optional)
Type:boolean
showInline (optional)
Type:boolean
input: Wait for interactive input

This step pauses Pipeline execution and allows the user to interact and control the flow of the build. Only a basic "proceed" or "abort" option is provided in the stage view.

You can optionally request information back, hence the name of the step. The parameter entry screen can be accessed via a link at the bottom of the build console log or via link in the sidebar for a build.

message

This parameter gives a prompt which will be shown to a human:

    Ready to go?
    Proceed or Abort
    

If you click "Proceed" the build will proceed to the next step, if you click "Abort" the build will be aborted.

Type:String
id (optional)

Every input step has an unique ID. It is used in the generated URL to proceed or abort.

A specific ID could be used, for example, to mechanically respond to the input from some external process/tool.

Type:String
ok (optional)
Type:String
parameters (optional)

Request that the submitter specify one or more parameter values when approving. If just one parameter is listed, its value will become the value of the input step. If multiple parameters are listed, the return value will be a map keyed by the parameter names. If parameters are not requested, the step returns nothing if approved.

On the parameter entry screen you are able to enter values for parameters that are defined in this field.

Array/List:
Nested choice of objects
booleanParam
name
Type:String
defaultValue (optional)
Type:boolean
description (optional)
Type:String
choice
name
Type:String
description (optional)
Type:String
choices (optional)
Nested choice of objects
(not enumerable)
credentials
Defines a credentials parameter, which you can use during a build.

For security reasons, the credential is NOT directly exposed, the ID of the credential is exposed.

However, the selected credential is available through variable substitution in some other parts of the configuration. The string value will be the ID of the credential. A supporting plugin can thus use the ID to retrieve the selected credential and expose it to the build in an appropriate way.
name
Type:String
defaultValue
The default credentials to use.
Type:String
credentialType
Type:String
required
When this option is selected, the credentials selection drop down will not provide the empty selection as one of the options. This will not prevent a build without a value if there are no credentials available, for example if the job does not have access to any credentials of the correct type or there is no default value and the user starting the build either does not have any credentials of the correct type in their personal credentials store or they do not have permissions on the job to use credentials from their personal store.
Type:boolean
description (optional)
Type:String
file
name
Type:String
description (optional)
Type:String
$class: 'ListSubversionTagsParameterDefinition'
When used, this parameter will display a field at build-time so that the user is able to select a Subversion tag from which to create the working copy for this project.

Once the two fields Name and Repository URL are set, you must

  1. ensure the job uses Subversion and
  2. set the Repository URL field of Subversion by concatenating the two fields of this parameter.
For instance, if Name is set to SVN_TAG and Repository URL is set to https://svn.jenkins-ci.org/tags, then Subversion's Repository URL must be set to https://svn.jenkins-ci.org/tags/$SVN_TAG.

Notice that you can set the Repository URL field to a Subversion repository root rather than just pointing to a tags dir (ie, you can set it to https://svn.jenkins-ci.org rather than https://svn.jenkins-ci.org/tags). In that case, if this repository root contains the trunk, branches and tags folders, then the dropdown will allow the user to pick the trunk, or a branch, or a tag.

name
Type:String
tagsDir
Specify the Subversion repository URL which contains the tags to be listed when triggering a new build.

You can also specify the root of a Subversion repository: If this root contains the trunk, branches and tags folders, then the dropdown will display trunk, all the branches and all the tags. If the root does not contain these three folders, then all its subfolders are listed in the dropdown.

When you enter the URL, Jenkins automatically checks if it can connect to it. If access requires authentication, you'll be prompted for the necessary credential. If you already have a working credential but would like to change it for some other reasons, you can manage credentials and specify a different credential.

Type:String
credentialsId
Type:String
tagsFilter
Specify a regular expression which will be used to filter the tags which are actually displayed when triggering a new build.
Type:String
defaultValue
For features such as SVN polling a default value is required. If job will only be started manually, this field is not necessary.
Type:String
maxTags
The maximum number of tags to display in the dropdown. Any non-number value will default to all.
Type:String
reverseByDate
Check this option so that tags are sorted from the newest to the oldest.

If this option is checked, the Sort Z to A one won't be taken into account.

Type:boolean
reverseByName
Check this option so that tags are displayed in reverse order (sorted Z to A).

Notice that if Sort newest first is checked, this option won't be taken into account.

Type:boolean
description (optional)
Type:String
password
Pass a password to your build. The password entered here is made available to the build in plain text as an environment variable like a string parameter would be. The value will be stored encrypted on the Jenkins controller, similar to passwords in Jenkins configuration.
name
Type:String
defaultValueAsSecret
org.kohsuke.stapler.NoStaplerConstructorException: There's no @DataBoundConstructor on any constructor of class hudson.util.Secret
description (optional)
Type:String
$class: 'PromotedBuildParameterDefinition'
name
Type:String
jobName
Type:String
process
Type:String
description (optional)
Type:String
run
name
Type:String
projectName
Type:String
filter
Values:
ALL
STABLE
SUCCESSFUL
COMPLETED
description (optional)
Type:String
string
name
Type:String
defaultValue (optional)
Type:String
description (optional)
Type:String
trim (optional)
Strip whitespace from the beginning and end of the string.
Type:boolean
text
name
Type:String
defaultValue (optional)
Type:String
description (optional)
Type:String
trim (optional)
Strip whitespace from the beginning and end of the string.
Type:boolean
submitter (optional)
User IDs and/or external group names of person or people permitted to respond to the input, separated by ','. Spaces will be trimmed. This means that "alice, bob, blah " is the same as "alice,bob,blah".
Note: Jenkins administrators are able to respond to the input regardless of the value of this parameter.
Type:String
submitterParameter (optional)
If specified, this is the name of the return value that will contain the ID of the user that approves this input. The return value will be handled in a fashion similar to the parameters value.
Type:String
isUnix: Checks if running on a Unix-like node
Returns true if enclosing node is running on a Unix-like system (such as Linux or Mac OS X), false if Windows.
javadoc: Publish Javadoc
javadocDir
Type:String
keepAll
If you check this option, Jenkins will retain Javadoc for each successful build. This allows you to browse Javadoc for older builds, at the expense of additional disk space requirement.

If you leave this option unchecked, Jenkins will only keep the latest Javadoc, so older Javadoc will be overwritten as new builds succeed.

Type:boolean
jobDsl: Process Job DSLs
additionalClasspath (optional)
Newline separated list of additional classpath entries for the Job DSL scripts. All entries must be relative to the workspace root, e.g. build/classes/main. Supports Ant-style patterns like lib/*.jar.
Type:String
additionalParameters (optional)
java.lang.UnsupportedOperationException: do not know how to categorize attributes of type java.util.Map<java.lang.String, java.lang.Object>
failOnMissingPlugin (optional)
If checked, the build will be marked as failed if a plugin must be installed or updated to support all features used in the DSL scripts. If not checked, the build will be marked as unstable instead.
Type:boolean
failOnSeedCollision (optional)
Fail build if generated item(s) have the same name as existing items already managed by another seed job. By default, this plugin will always regenerate all jobs and views, thus updating previously generated jobs and views even if managed by another seed job. Check this box if you wish to fail the job if a generated item name collision is detected.
Type:boolean
ignoreExisting (optional)
Ignore previously generated jobs and views. By default, this plugin will always regenerate all jobs and views, thus updating previously generated jobs and views. Check this box if you wish to leave previous jobs and views as is.
Type:boolean
ignoreMissingFiles (optional)
Ignore missing DSL scripts. If not checked, the build step will fail if a configured script is missing or if a wildcard does not match any files.
Type:boolean
lookupStrategy (optional)
Determines how relative job names in DSL scripts are interpreted. You will only see a difference when the seed job is located in a folder.
  • Jenkins Root When this option is selected relative job names are always interpreted relative to the Jenkins root.
  • Seed Job If you choose this option relative job names in DSL scripts will be interpreted relative to the folder in which the seed job is located. Suppose you have a seed job which is located in a folder named seedJobFolder and a DSL script which creates a job named subfolder2/job. The job that is created by the seed job will be at the location /seedJobFolder/subfolder2/job.
Values:
JENKINS_ROOT
SEED_JOB
removedConfigFilesAction (optional)
Specifies what to do when previously generated config files are not referenced anymore.

Note: when using multiple Job DSL build steps in a single job, set this to "Delete" only for the last Job DSL build step. Otherwise config files may be deleted and re-created. See JENKINS-44142 for details.

Values:
IGNORE
DELETE
removedJobAction (optional)
Specifies what to do when a previously generated job is not referenced anymore.

Note: when using multiple Job DSL build steps in a single job, set this to "Delete" or "Disable" only for the last Job DSL build step. Otherwise jobs will be deleted and re-created or disabled and re-enabled and you may lose the job history of generated jobs. See JENKINS-44142 for details.

Values:
IGNORE
DISABLE
DELETE
removedViewAction (optional)
Specifies what to do when a previously generated view is not referenced anymore.

Note: when using multiple Job DSL build steps in a single job, set this to "Delete" only for the last Job DSL build step. Otherwise views may be deleted and re-created. See JENKINS-44142 for details.

Values:
IGNORE
DELETE
sandbox (optional)
If checked, runs the DSL scripts in a sandbox with limited abilities. You will also need to configure this job to run with the identity of a particular user. If unchecked, and you are not a Jenkins administrator, you will need to wait for an administrator to approve the scripts.
Type:boolean
scriptText (optional)
DSL Script, which is groovy code. Look at documentation for details on the syntax.
Type:String
targets (optional)
Newline separated list of DSL scripts, located in the Workspace. Can use wildcards like 'jobs/**/*.groovy'. See the @includes of Ant fileset for the exact format.

Scripts are executed in the same order as specified. The execution order of expanded wildcards is unspecified.

Type:String
unstableOnDeprecation (optional)
If checked, marks the build as unstable when using deprecated features. If not checked, a warning will be printed to the build log only.
Type:boolean
useScriptText (optional)
Type:boolean
junit: Archive JUnit-formatted test results
Jenkins understands the JUnit test report XML format (which is also used by TestNG). When this option is configured, Jenkins can provide useful information about test results, such as historical test result trends, a web UI for viewing test reports, tracking failures, and so on.

To use this feature, first set up your build to run tests, then specify the path to JUnit XML files in the Ant glob syntax, such as **/build/test-reports/*.xml. Be sure not to include any non-report files into this pattern. You can specify multiple patterns of files separated by commas.

testResults
Type:String
allowEmptyResults (optional)
If checked, the default behavior of failing a build on missing test result files or empty test results is changed to not affect the status of the build. Please note that this setting make it harder to spot misconfigured jobs or build failures where the test tool does not exit with an error code when not producing test report files.
Type:boolean
checksName (optional)
If provided, and publishing checks enabled, the plugin will use this name when publishing results to corresponding SCM hosting platforms. If not, a default including the current stage / branch names will be used.
Type:String
healthScaleFactor (optional)
The amplification factor to apply to test failures when computing the test result contribution to the build health score.
The default factor is 1.0
  • A factor of 0.0 will disable the test result contribution to build health score.
  • A factor of 0.1 means that 10% of tests failing will score 99% health
  • A factor of 0.5 means that 10% of tests failing will score 95% health
  • A factor of 1.0 means that 10% of tests failing will score 90% health
  • A factor of 2.0 means that 10% of tests failing will score 80% health
  • A factor of 2.5 means that 10% of tests failing will score 75% health
  • A factor of 5.0 means that 10% of tests failing will score 50% health
  • A factor of 10.0 means that 10% of tests failing will score 0% health
The factor is persisted with the build results, so changes will only be reflected in new builds.
Type:double
keepLongStdio (optional)
If checked, any standard output or error from a test suite will be retained in the test results after the build completes. (This refers only to additional messages printed to console, not to a failure stack trace.) Such output is always kept if the test failed, but by default lengthy output from passing tests is truncated to save space. Check this option if you need to see every log message from even passing tests, but beware that Jenkins's memory consumption can substantially increase as a result, even if you never look at the test results!
Type:boolean
skipMarkingBuildUnstable (optional)
If this option is unchecked, then the plugin will mark the build as unstable when it finds at least 1 test failure. If this option is checked, then the build will still be successful even if there are test failures reported. In any case, the corresponding pipeline node (and stage) will be marked as unstable in case of test failure.
Type:boolean
skipOldReports (optional)
Type:boolean
skipPublishingChecks (optional)
If this option is unchecked, then the plugin automatically publishes the test results to corresponding SCM hosting platforms. For example, if you are using this feature for a GitHub organization project, the warnings will be published to GitHub through the Checks API. If this operation slows down your build, or you don't want to publish the warnings to SCM platforms, you can use this option to deactivate this feature.
Type:boolean
testDataPublishers (optional)
Array/List:
Nested choice of objects
kubeconfig: Setup Kubernetes CLI (kubectl)
Configure Kubernetes client (kubectl) so it can be used in the build to run Kubernetes commands
serverUrl
URL of the Kubernetes API endpoint. If not set the connection options will be autoconfigured from service account or kube config file.
Type:String
credentialsId
Type:String
caCertificate
The base64 encoded certificate of the certificate authority (CA). It is used to verify the server certificate.

Leaving this field empty will skip the certificate verification.

Type:String
library: Load a library on the fly

Load a library dynamically rather than using @Library syntax. You may use global variables defined in the library thereafter:


library 'mylib@master'
usefulFunction()

You may also load classes defined in the library by selecting their fully-qualified names like properties on the return value of this step, then call static methods or call constructors as if they were a method named new:


def utils = library('mylib').com.mycorp.jenkins.Utils.new(this)
utils.handyStuff()
identifier
A library name to load. Should normally match that of a predefined library. You can append a version after @. You may instead define a library inline here.
Type:String
changelog (optional)
Whether to include any changes in the library in the recent changes of jobs using the library. Defaults to including the changes.
Type:boolean
retriever (optional)
Nested choice of objects
legacySCM
scm
Nested choice of objects
$class: 'GitSCM'

The git plugin provides fundamental git operations for Jenkins projects. It can poll, fetch, checkout, and merge contents of git repositories.

The git plugin provides an SCM implementation to be used with the Pipeline SCM checkout step. The Pipeline Syntax Snippet Generator guides the user to select git plugin checkout options and provides online help for each of the options.

userRemoteConfigs
Specify the repository to track. This can be a URL or a local file path. Note that for super-projects (repositories with submodules), only a local file path or a complete URL is valid. The following are examples of valid git URLs.
  • ssh://git@github.com/github/git.git
  • git@github.com:github/git.git (short notation for ssh protocol)
  • ssh://user@other.host.com/~/repos/R.git (to access the repos/R.git repository in the user's home directory)
  • https://github.com/github/git.git

If the repository is a super-project, the location from which to clone submodules is dependent on whether the repository is bare or non-bare (i.e. has a working directory).
  • If the super-project is bare, the location of the submodules will be taken from .gitmodules.
  • If the super-project is not bare, it is assumed that the repository has each of its submodules cloned and checked out appropriately. Thus, the submodules will be taken directly from a path like ${SUPER_PROJECT_URL}/${SUBMODULE}, rather than relying on information from .gitmodules.
For a local URL/path to a super-project, git rev-parse --is-bare-repository is used to detect whether the super-project is bare or not.
For a remote URL to a super-project, the ending of the URL determines whether a bare or non-bare repository is assumed:
  • If the remote URL ends with /.git, a non-bare repository is assumed.
  • If the remote URL does NOT end with /.git, a bare repository is assumed.
Array/List:
Nested object
url
Specify the URL or path of the git repository. This uses the same syntax as your git clone command.
Type:String
name
ID of the repository, such as origin, to uniquely identify this repository among other remote repositories. This is the same "name" that you use in your git remote command. If left empty, Jenkins will generate unique names for you.

You normally want to specify this when you have multiple remote repositories.

Type:String
refspec
A refspec controls the remote refs to be retrieved and how they map to local refs. If left blank, it will default to the normal behaviour of git fetch, which retrieves all the branch heads as remotes/REPOSITORYNAME/BRANCHNAME. This default behaviour is OK for most cases.

In other words, the default refspec is "+refs/heads/*:refs/remotes/REPOSITORYNAME/*" where REPOSITORYNAME is the value you specify in the above "name of repository" textbox.

When do you want to modify this value? A good example is when you want to just retrieve one branch. For example, +refs/heads/master:refs/remotes/origin/master would only retrieve the master branch and nothing else.

The plugin uses a default refspec for its initial fetch, unless the "Advanced Clone Option" is set to honor refspec. This keeps compatibility with previous behavior, and allows the job definition to decide if the refspec should be honored on initial clone.

Multiple refspecs can be entered by separating them with a space character. +refs/heads/master:refs/remotes/origin/master +refs/heads/develop:refs/remotes/origin/develop retrieves the master branch and the develop branch and nothing else.

See the refspec definition in Git user manual for more details.

Type:String
credentialsId
Credential used to check out sources.
Type:String
branches
List of branches to build. Jenkins jobs are most effective when each job builds only a single branch. When a single job builds multiple branches, the changelog comparisons between branches often show no changes or incorrect changes.
Array/List:
Nested object
name

Specify the branches if you'd like to track a specific branch in a repository. If left blank, all branches will be examined for changes and built.

The safest way is to use the refs/heads/<branchName> syntax. This way the expected branch is unambiguous.

If your branch name has a / in it make sure to use the full reference above. When not presented with a full path the plugin will only use the part of the string right of the last slash. Meaning foo/bar will actually match bar.

If you use a wildcard branch specifier, with a slash (e.g. release/), you'll need to specify the origin repository in the branch names to make sure changes are picked up. So e.g. origin/release/

Possible options:

  • <branchName>
    Tracks/checks out the specified branch. If ambiguous the first result is taken, which is not necessarily the expected one. Better use refs/heads/<branchName>.
    E.g. master, feature1, ...
  • refs/heads/<branchName>
    Tracks/checks out the specified branch.
    E.g. refs/heads/master, refs/heads/feature1/master, ...
  • <remoteRepoName>/<branchName>
    Tracks/checks out the specified branch. If ambiguous the first result is taken, which is not necessarily the expected one.
    Better use refs/heads/<branchName>.
    E.g. origin/master
  • remotes/<remoteRepoName>/<branchName>
    Tracks/checks out the specified branch.
    E.g. remotes/origin/master
  • refs/remotes/<remoteRepoName>/<branchName>
    Tracks/checks out the specified branch.
    E.g. refs/remotes/origin/master
  • <tagName>
    This does not work since the tag will not be recognized as tag.
    Use refs/tags/<tagName> instead.
    E.g. git-2.3.0
  • refs/tags/<tagName>
    Tracks/checks out the specified tag.
    E.g. refs/tags/git-2.3.0
  • <commitId>
    Checks out the specified commit.
    E.g. 5062ac843f2b947733e6a3b105977056821bd352, 5062ac84, ...
  • ${ENV_VARIABLE}
    It is also possible to use environment variables. In this case the variables are evaluated and the result is used as described above.
    E.g. ${TREEISH}, refs/tags/${TAGNAME}, ...
  • <Wildcards>
    The syntax is of the form: REPOSITORYNAME/BRANCH. In addition, BRANCH is recognized as a shorthand of */BRANCH, '*' is recognized as a wildcard, and '**' is recognized as wildcard that includes the separator '/'. Therefore, origin/branches* would match origin/branches-foo but not origin/branches/foo, while origin/branches** would match both origin/branches-foo and origin/branches/foo.
  • :<regular expression>
    The syntax is of the form: :regexp. Regular expression syntax in branches to build will only build those branches whose names match the regular expression.
    Examples:
    • :^(?!(origin/prefix)).*
      • matches: origin or origin/master or origin/feature
      • does not match: origin/prefix or origin/prefix_123 or origin/prefix-abc
    • :origin/release-\d{8}
      • matches: origin/release-20150101
      • does not match: origin/release-2015010 or origin/release-201501011 or origin/release-20150101-something
    • :^(?!origin/master$|origin/develop$).*
      • matches: origin/branch1 or origin/branch-2 or origin/master123 or origin/develop-123
      • does not match: origin/master or origin/develop

Type:String
browser
Defines the repository browser that displays changes detected by the git plugin.
Nested choice of objects
$class: 'AssemblaWeb'
repoUrl
Specify the root URL serving this repository (such as https://www.assembla.com/code/PROJECT/git/).
Type:String
bitbucketServer
repoUrl
Specify the Bitbucket Server root URL for this repository (such as https://bitbucket:7990/OWNER/REPO/).
Type:String
$class: 'BitbucketWeb'
repoUrl
Specify the root URL serving this repository (such as https://bitbucket.org/OWNER/REPO/).
Type:String
$class: 'CGit'
repoUrl
Specify the root URL serving this repository (such as http://cgit.example.com:port/group/REPO/).
Type:String
$class: 'FisheyeGitRepositoryBrowser'
repoUrl
Specify the URL of this repository in FishEye (such as http://fisheye6.cenqua.com/browse/ant/).
Type:String
$class: 'GitBlitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository.
Type:String
projectName
Specify the name of the project in GitBlit.
Type:String
$class: 'GitLab'
repoUrl
Specify the root URL serving this repository (such as http://gitlabserver:port/group/REPO/).
Type:String
version (optional)
Specify the major and minor version of GitLab you use (such as 9.1). If you don't specify a version, a modern version of GitLab (>= 8.0) is assumed.
Type:String
$class: 'GitList'
repoUrl
Specify the root URL serving this repository (such as http://gitlistserver:port/REPO/).
Type:String
$class: 'GitWeb'
repoUrl
Specify the root URL serving this repository (such as https://github.com/jenkinsci/jenkins.git).
Type:String
$class: 'GithubWeb'
repoUrl
Specify the HTTP URL for this repository's GitHub page (such as https://github.com/jquery/jquery).
Type:String
$class: 'Gitiles'
repoUrl
Specify the root URL serving this repository (such as https://gwt.googlesource.com/gwt/).
Type:String
$class: 'GitoriousWeb'
repoUrl
Specify the root URL serving this repository (such as https://gitorious.org/gitorious/mainline).
Type:String
$class: 'GogsGit'
repoUrl
Specify the root URL serving this repository (such as http://gogs.example.com:port/username/some-repo-url.git).
Type:String
$class: 'KilnGit'
repoUrl
Specify the root URL serving this repository (such as https://khanacademy.kilnhg.com/Code/Website/Group/webapp).
Type:String
$class: 'Phabricator'
repoUrl
Specify the phabricator instance root URL (such as http://phabricator.example.com).
Type:String
repo
Specify the repository name in phabricator (such as the foo part of phabricator.example.com/diffusion/foo/browse).
Type:String
$class: 'RedmineWeb'
repoUrl
Specify the root URL serving this repository (such as http://SERVER/PATH/projects/PROJECT/repository).
Type:String
$class: 'RhodeCode'
repoUrl
Specify the HTTP URL for this repository's RhodeCode page (such as http://rhodecode.mydomain.com:5000/projects/PROJECT/repos/REPO/).
Type:String
$class: 'ScmManagerGitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository (such as https://scm-manager.org/scm/repo/namespace/name).
Type:String
$class: 'Stash'
repoUrl
Specify the HTTP URL for this repository's Stash page (such as http://stash.mydomain.com:7990/projects/PROJECT/repos/REPO/).
Type:String
$class: 'TFS2013GitRepositoryBrowser'
repoUrl
Either the name of the remote whose URL should be used, or the URL of this module in TFS (such as http://fisheye6.cenqua.com/tfs/PROJECT/_git/REPO/). If empty (default), the URL of the "origin" repository is used.

If TFS is also used as the repository server, this can usually be left blank.

Type:String
$class: 'ViewGitWeb'
repoUrl
Specify the root URL serving this repository (such as http://code.fealdia.org/viewgit/).
Type:String
projectName
Specify the name of the project in ViewGit (e.g. scripts, scuttle etc. from http://code.fealdia.org/viewgit/).
Type:String
gitTool

Absolute path to the git executable.

This is different from other Jenkins tool definitions. Rather than providing the directory that contains the executable, you must provide the complete path to the executable. Setting '/usr/bin/git' would be correct, while setting '/usr/bin/' is not correct.

Type:String
extensions

Extensions add new behavior or modify existing plugin behavior for different uses. Extensions help users more precisely tune plugin behavior to meet their needs.

Extensions include:

  • Clone extensions modify the git operations that retrieve remote changes into the agent workspace. The extensions can adjust the amount of history retrieved, how long the retrieval is allowed to run, and other retrieval details.
  • Checkout extensions modify the git operations that place files in the workspace from the git repository on the agent. The extensions can adjust the maximum duration of the checkout operation, the use and behavior of git submodules, the location of the workspace on the disc, and more.
  • Changelog extensions adapt the source code difference calculations for different cases.
  • Tagging extensions allow the plugin to apply tags in the current workspace.
  • Build initiation extensions control the conditions that start a build. They can ignore notifications of a change or force a deeper evaluation of the commits when polling.
  • Merge extensions can optionally merge changes from other branches into the current branch of the agent workspace. They control the source branch for the merge and the options applied to the merge.

Array/List:
Nested choice of objects
$class: 'AuthorInChangelog'
The default behavior is to use the Git commit's "Committer" value in Jenkins' build changesets. If this option is selected, the Git commit's "Author" value would be used instead.
$class: 'BuildChooserSetting'
When you are interested in using a job to build multiple heads (most typically multiple branches), you can choose how Jenkins choose what branches to build in what order.

This extension point in Jenkins is used by many other plugins to control the job to build specific commits. When you activate those plugins, you may see them installing a custom strategy here.

buildChooser
Nested choice of objects
$class: 'AncestryBuildChooser'
maximumAgeInDays
Type:int
ancestorCommitSha1
Type:String
$class: 'DefaultBuildChooser'
$class: 'InverseBuildChooser'
$class: 'BuildSingleRevisionOnly'
Disable scheduling for multiple candidate revisions.
If we have 3 branches:
----A--.---.--- B
         \-----C
jenkins would try to build (B) and (C).
This behaviour disables this and only builds one of them.
It is helpful to reduce the load of the Jenkins infrastructure when the SCM system like Bitbucket or GitHub should decide what commits to build.
$class: 'ChangelogToBranch'
This method calculates the changelog against the specified branch.
options
Nested object
compareRemote
Name of the repository, such as origin, that contains the branch you specify below.
Type:String
compareTarget
The name of the branch within the named repository to compare against.
Type:String
$class: 'CheckoutOption'
timeout
Specify a timeout (in minutes) for checkout.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
$class: 'CleanBeforeCheckout'
Clean up the workspace before every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CleanCheckout'
Clean up the workspace after every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CloneOption'
shallow
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
noTags
Deselect this to perform a clone without tags, saving time and disk space when you just want to access what is specified by the refspec.
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
Type:String
timeout
Specify a timeout (in minutes) for clone and fetch operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
honorRefspec (optional)
Perform initial clone using the refspec defined for the repository. This can save time, data transfer and disk space when you only need to access the references specified by the refspec.
Type:boolean
$class: 'DisableRemotePoll'
Git plugin uses git ls-remote polling mechanism by default when configured with a single branch (no wildcards!). This compare the latest built commit SHA with the remote branch without cloning a local copy of the repo.

If you don't want to / can't use this.

If this option is selected, polling will require a workspace and might trigger unwanted builds (see JENKINS-10131).
$class: 'GitLFSPull'
Enable git large file support for the workspace by pulling large files after the checkout completes. Requires that the controller and each agent performing an LFS checkout have installed `git lfs`.
$class: 'IgnoreNotifyCommit'
If checked, this repository will be ignored when the notifyCommit-URL is accessed regardless of if the repository matches or not.
$class: 'LocalBranch'
If given, checkout the revision to build as HEAD on this branch.

If selected, and its value is an empty string or "**", then the branch name is computed from the remote branch without the origin. In that case, a remote branch origin/master will be checked out to a local branch named master, and a remote branch origin/develop/new-feature will be checked out to a local branch named develop/newfeature.

Please note that this has not been tested with submodules.

localBranch
Type:String
$class: 'MessageExclusion'
excludedMessage
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions committed with message matched to Pattern when determining if a build needs to be triggered. This can be used to exclude commits done by the build itself from triggering another build, assuming the build server commits the change with a distinct message.

Exclusion uses Pattern matching

.*\[maven-release-plugin\].*
The example above illustrates that if only revisions with "[maven-release-plugin]" message in first comment line have been committed to the SCM a build will not occur.

You can create more complex patterns using embedded flag expressions.

(?s).*FOO.*
This example will search FOO message in all comment lines.
Type:String
$class: 'PathRestriction'
If set, and Jenkins is set to poll for changes, Jenkins will pay attention to included and/or excluded files and/or folders when determining if a build needs to be triggered.

Using this behaviour will preclude the faster git ls-remote polling mechanism, forcing polling to require a workspace thus sometimes triggering unwanted builds, as if you had selected the Force polling using workspace extension as well.

includedRegions
Each inclusion uses java regular expression pattern matching, and must be separated by a new line. An empty list implies that everything is included.

    myapp/src/main/web/.*\.html
    myapp/src/main/web/.*\.jpeg
    myapp/src/main/web/.*\.gif
  
The example above illustrates that a build will only occur, if html/jpeg/gif files have been committed to the SCM. Exclusions take precedence over inclusions, if there is an overlap between included and excluded regions.
Type:String
excludedRegions
Each exclusion uses java regular expression pattern matching, and must be separated by a new line.

    myapp/src/main/web/.*\.html
    myapp/src/main/web/.*\.jpeg
    myapp/src/main/web/.*\.gif
  
The example above illustrates that if only html/jpeg/gif files have been committed to the SCM a build will not occur.
Type:String
$class: 'PerBuildTag'
Create a tag in the workspace for every build to unambiguously mark the commit that was built. You can combine this with Git publisher to push the tags to the remote repository.
$class: 'PreBuildMerge'
These options allow you to perform a merge to a particular branch before building. For example, you could specify an integration branch to be built, and to merge to master. In this scenario, on every change of integration, Jenkins will perform a merge with the master branch, and try to perform a build if the merge is successful. It then may push the merge back to the remote repository if the Git Push post-build action is selected.
options
Nested object
mergeTarget
The name of the branch within the named repository to merge to, such as master.
Type:String
fastForwardMode (optional)
Merge fast-forward mode selection.
The default, --ff, gracefully falls back to a merge commit when required.
For more information, see the Git Merge Documentation
Values:
FF
FF_ONLY
NO_FF
mergeRemote (optional)
Name of the repository, such as origin, that contains the branch you specify below. If left blank, it'll default to the name of the first repository configured above.
Type:String
mergeStrategy (optional)
Merge strategy selection. This feature is not fully implemented in JGIT.
Values:
DEFAULT
RESOLVE
RECURSIVE
OCTOPUS
OURS
SUBTREE
RECURSIVE_THEIRS
$class: 'PruneStaleBranch'
Run "git remote prune" for each remote, to prune obsolete local branches.
pruneTags
pruneTags
Type:boolean
$class: 'RelativeTargetDirectory'
relativeTargetDir
Specify a local directory (relative to the workspace root) where the Git repository will be checked out. If left empty, the workspace root itself will be used.

This extension should not be used in Jenkins Pipeline (either declarative or scripted). Jenkins Pipeline already provides standard techniques for checkout to a subdirectory. Use ws and dir in Jenkins Pipeline rather than this extension.

Type:String
$class: 'ScmName'

Unique name for this SCM. Needed when using Git within the Multi SCM plugin.

name
Type:String
$class: 'SparseCheckoutPaths'

Specify the paths that you'd like to sparse checkout. This may be used for saving space (Think about a reference repository). Be sure to use a recent version of Git, at least above 1.7.10

sparseCheckoutPaths
Array/List:
Nested object
path
Type:String
$class: 'SubmoduleOption'
disableSubmodules
By disabling support for submodules you can still keep using basic git plugin functionality and just have Jenkins to ignore submodules completely as if they didn't exist.
Type:boolean
recursiveSubmodules
Retrieve all submodules recursively (uses '--recursive' option which requires git>=1.6.5)
Type:boolean
trackingSubmodules
Retrieve the tip of the configured branch in .gitmodules (Uses '--remote' option which requires git>=1.8.2)
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
To prepare a reference folder with multiple subprojects, create a bare git repository and add all the remote urls then perform a fetch:
  git init --bare
  git remote add SubProject1 https://gitrepo.com/subproject1
  git remote add SubProject2 https://gitrepo.com/subproject2
  git fetch --all
  
Type:String
timeout
Specify a timeout (in minutes) for submodules operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
parentCredentials
Use credentials from the default remote of the parent project.
Type:boolean
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
shallow (optional)
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
threads (optional)
Specify the number of threads that will be used to update submodules.
If unspecified, the command line git default thread count is used.
Type:int
$class: 'UserExclusion'
excludedUsers
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions committed by users in this list when determining if a build needs to be triggered. This can be used to exclude commits done by the build itself from triggering another build, assuming the build server commits the change with a distinct SCM user.

Using this behaviour will preclude the faster git ls-remote polling mechanism, forcing polling to require a workspace thus sometimes triggering unwanted builds, as if you had selected the Force polling using workspace extension as well.

Each exclusion uses exact string comparison and must be separated by a new line. User names are only excluded if they exactly match one of the names in this list.

auto_build_user
The example above illustrates that if only revisions by "auto_build_user" have been committed to the SCM a build will not occur.
Type:String
$class: 'UserIdentity'
name

If given, "GIT_COMMITTER_NAME=[this]" and "GIT_AUTHOR_NAME=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
email

If given, "GIT_COMMITTER_EMAIL=[this]" and "GIT_AUTHOR_EMAIL=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
$class: 'WipeWorkspace'
Delete the contents of the workspace before building, ensuring a fully fresh workspace.
doGenerateSubmoduleConfigurations (optional)

Removed facility that was intended to test combinations of git submodule versions. Removed in git plugin 4.6.0. Ignores the user provided value and always uses false as its value.

Type:boolean
submoduleCfg (optional)

Removed facility that was intended to test combinations of git submodule versions. Removed in git plugin 4.6.0. Ignores the user provided value(s) and always uses empty values.

Array/List:
Nested object
submoduleName

Removed in git plugin 4.6.0.

Type:String
branches

Removed in git plugin 4.6.0.

Array/List:
Type:String
$class: 'MercurialSCM'
source
Specify the repository to track. This can be URL or a local file path. If you are specifying HTTP credentials, do not include a username in the URL.
Type:String
browser (optional)
Nested choice of objects
$class: 'FishEye'
url
Specify the root URL serving this repository, such as: http://www.example.org/browse/hg/
Type:String
$class: 'GoogleCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'HgWeb'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'Kallithea'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'KilnHG'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCodeLegacy'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'ScmManager'
url
Specify the root URL serving this repository (such as http://YOURSCMMANAGER/scm/repo/NAMESPACE/NAME/).
Type:String
clean (optional)
When this option is checked, each build will wipe any local modifications or untracked files in the repository checkout. This is often a convenient way to ensure that a build is not using any artifacts from earlier builds.
Type:boolean
credentialsId (optional)
Optional credentials to use when cloning or pulling from the remote repository. Supports username/password with HTTP(S) URLs, and SSH private key with SSH URLs.
Type:String
disableChangeLog (optional)
When checked, Hudson will not calculate the Mercurial changelog for each build. Disabling the changelog can decrease the amount of time needed to update a very large repository.
Type:boolean
installation (optional)
Type:String
modules (optional)
Reduce unnecessary builds by specifying a comma or space delimited list of "modules" within the repository. A module is a directory name within the repository that this project lives in. If this field is set, changes outside the specified modules will not trigger a build (even though the whole repository is checked out anyway due to the Mercurial limitation.)
Type:String
revision (optional)
Specify the branch or tag name you would like to track. (If you do not type anything, the default value is the default branch.)
Type:String
revisionType (optional)
Specify the kind of revision you expect Jenkins to update your working copy to.
Values:
BRANCH
TAG
CHANGESET
REVSET
subdir (optional)
If not empty, check out the Mercurial repository into this subdirectory of the job's workspace. For example: my/sources (use forward slashes). If changing this entry, you probably want to clean the workspace first.
Type:String
none
$class: 'SubversionSCM'
Checks out the source code from Subversion repositories. See post-commit hook set up for improved turn-around time and performance in polling.
locations
Array/List:
Nested object
remote
Type:String
credentialsId
Type:String
local
Specify a local directory (relative to the workspace root) where this module is checked out. If left empty, the last path component of the URL is used as the default, just like the svn CLI. A single period (.) may be used to check out the project directly into the workspace rather than into a subdirectory.
Type:String
depthOption
--depth option for checkout and update commands. Default value is infinity.
  • empty includes only the immediate target of the operation, not any of its file or directory children.
  • files includes the immediate target of the operation and any of its immediate file children.
  • immediates includes the immediate target of the operation and any of its immediate file or directory children. The directory children will themselves be empty.
  • infinity includes the immediate target, its file and directory children, its children's children, and so on to full recursion.
  • as-it-is takes the working depth from the current working copy, allows for setting update depth manually using --set-depth option.
More information can be found here.
Type:String
ignoreExternalsOption
"--ignore-externals" option will be used with svn checkout, svn update commands to disable externals definition processing.

More information can be found here.
Note: there is the potential to leverage svn:externals to gain read access to the entire Subversion repository. This can happen if you follow the normal practice of giving Jenkins credentials with read access to the entire Subversion repository. You will also need to provide the credentials to use when checking/polling out the svn:externals using the Additional Credentials option.

Type:boolean
cancelProcessOnExternalsFail
Determines if the process should be cancelled when checkout/update svn:externals failed. Will work when "Ignore externals" box is not checked. Default choice is to cancelled the process when checkout/update svn:externals failed.
Type:boolean
workspaceUpdater
Nested choice of objects
$class: 'CheckoutUpdater'
$class: 'NoopUpdater'
$class: 'UpdateUpdater'
$class: 'UpdateWithCleanUpdater'
$class: 'UpdateWithRevertUpdater'
browser
Nested choice of objects
$class: 'Assembla'
spaceName
Type:String
$class: 'CollabNetSVN'
url
The repository browser URL for the root of the project. For example, a Java.net project called myproject would use https://myproject.dev.java.net/source/browse/myproject.
Type:String
$class: 'FishEyeSVN'
url
Specify the URL of this module in FishEye. (such as http://fisheye6.cenqua.com/browse/ant/)
Type:String
rootModule
Specify the root Subversion module that this FishEye monitors. For example, for http://fisheye6.cenqua.com/browse/ant/, this field would be ant because it displays the directory "/ant" of the ASF repo. If FishEye is configured to display the whole SVN repository, leave this field empty.
Type:String
svnPhabricator
url
Type:String
repo
Type:String
$class: 'SVNWeb'
url
Type:String
$class: 'ScmManagerSvnRepositoryBrowser'
repoUrl
Specify the root URL serving this repository (such as https://scm-manager.org/scm/repo/namespace/name).
Type:String
$class: 'Sventon'
url
Specify the URL of the Sventon repository browser. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be http://somehost.com/svn/
Type:String
repositoryInstance
Specify the Sventon repository instance name that references this subversion repository. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be local
Type:String
$class: 'Sventon2'
url
Specify the URL of the Sventon repository browser. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be http://somehost.com/svn/
Type:String
repositoryInstance
Specify the Sventon repository instance name that references this subversion repository. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be local
Type:String
$class: 'ViewSVN'
url
Specify the root URL of ViewSVN for this repository (such as this).
Type:String
$class: 'VisualSVN'
url
Specify the root URL of VisualSVN for this repository (such as https://demo-server.visualsvn.com/!/#tortoisesvn).
Type:String
$class: 'WebSVN'
url
Type:String
excludedRegions
If set, and Jenkins is set to poll for changes, Jenkins will ignore any files and/or folders in this list when determining if a build needs to be triggered.

Each exclusion uses regular expression pattern matching, and must be separated by a new line.

	/trunk/myapp/src/main/web/.*\.html
	/trunk/myapp/src/main/web/.*\.jpeg
	/trunk/myapp/src/main/web/.*\.gif
  
The example above illustrates that if only html/jpeg/gif files have been committed to the SCM a build will not occur.

More information on regular expressions can be found here.

Type:String
excludedUsers
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions committed by users in this list when determining if a build needs to be triggered. This can be used to exclude commits done by the build itself from triggering another build, assuming the build server commits the change with a distinct SCM user.

Each exclusion uses literal pattern matching, and must be separated by a new line.

	 auto_build_user
  
The example above illustrates that if only revisions by "auto_build_user" have been committed to the SCM a build will not occur.
Type:String
excludedRevprop
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions that are marked with the given revision property (revprop) when determining if a build needs to be triggered. This can be used to exclude commits done by the build itself from triggering another build, assuming the build server commits the change with the correct revprop.

This type of exclusion only works with Subversion 1.5 servers and newer.

More information on revision properties can be found here.

Type:String
excludedCommitMessages
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions with commit messages containing any of the given regular expressions when determining if a build needs to be triggered.
Type:String
includedRegions
If set, and Jenkins is set to poll for changes, Jenkins will ignore any files and/or folders that are not in this list when determining if a build needs to be triggered.

Each inclusion uses regular expression pattern matching, and must be separated by a new line.

This is useful when you need to check out an entire resource for building, but only want to do the build when a subset has changed.

	/trunk/myapp/c/library1/.*
	/trunk/myapp/c/library2/.*
  
If /trunk/myapp is checked out, the build will only occur when there are changes to either the c/library1 and c/library2 subtrees.

If there are also excluded regions specified, then a file is not ignored when it is in the included list and not in the excluded list.

More information on regular expressions can be found here.

Type:String
ignoreDirPropChanges
If set, Jenkins ignores svn-property only changes of directories. These changes are ignored when determining whether a build should be triggered and are removed from a build's changeset. Main usage of this property is to ignore svn:mergeinfo changes (which would otherwise e.g. lead to a complete rebuild of a maven project, in spite of incremental build option).
Type:boolean
filterChangelog
If set Jenkins will apply the same inclusion and exclusion patterns for displaying changelog entries as it does for polling for changes. If this is disabled, changes which are excluded for polling are still displayed in the changelog.
Type:boolean
additionalCredentials

If there are additional credentials required in order to obtain a complete checkout of the source, they can be provided here.

The realm is how the repository self-identifies to a client. It usually has the following format:

<proto://host:port> Realm Name

  • proto is the protocol, e.g. http or svn.
  • host is the host how it's accessed by Jenkins, e.g. as IP address 192.168.1.100, host name svnserver, or host name and domain svn.example.org.
  • port is the port, even if not explicitly specified. By default, this is 80 for HTTP, 443 for HTTPS, 3690 for the svn protocol.
  • Realm Name is how the repository self-identifies. Common options include VisualSVN Server, Subversion Authentication or the UUID of the repository.

To find out the realm, you could do any of the following:

  • If you access the repository via HTTP or HTTPS: Open the repo in a web browser without saved credentials. It will use the Realm Name (see above) in the authentication dialog.
  • Use the command line svn program.
    • If you don't have stored the credentials, run e.g. svn info https://svnserver/repo and it will tell you the realm when asking you to enter a password, e.g.: Authentication realm: <svn://svnserver:3690> VisualSVN Server.
    • If you have already stored the credentials to access the repository, look for the realm name in one of the files in ~/.subversion/auth/svn/simple; it will be two lines below the line svn:realmstring.
  • When accessing a repository via the svn+ssh protocol, the realm has the format username@svn+ssh://host:port – note that the username is before the svn+ssh:// (unlike the URL used for normal SVN operations), and that there are no angle brackets and no realm name. For this protocol the default port is 22.

Make sure to enter the realm exactly as shown, starting with a < (except for repositories accessed via svn+ssh – see above).

Array/List:
Nested object
realm
This is the realm that the SvnKit library associates with a specific checkout. For most Subversion servers this will typically be of the format <scheme://hostname(:port)> name, while for servers accessed via svn+ssh it is of the format (username@)svn+ssh://hostname(:port).
Type:String
credentialsId
Select the credential from the list of relevant credentials in order to use that credential for checking out the source code.
Type:String
quietOperation

Mimics subversion command line --quiet parameter for check out / update operations to help keep the output shorter. Prints nothing, or only summary information.

Type:boolean
libraryPath (optional)
A relative path from the root of the SCM to the root of the library. Leave this field blank if the root of the library is the root of the SCM. Note that ".." is not permitted as a path component to avoid security issues.
Type:String
modernSCM
scm
Nested choice of objects
bitbucket
Discovers branches and/or pull requests from a specific repository in either Bitbucket Cloud or a Bitbucket Server instance.
repoOwner
Specify the name of the Bitbucket Team or Bitbucket User Account.

It could be a Bitbucket Project also, if using Bitbucket Server. In this case (Bitbucket Server):

  • Use the project key, not the project name.
  • If using a user account instead of a project, add a "~" character before the username, i.e. "~joe".
Type:String
repository
The repository to scan.
Type:String
autoRegisterHook (optional)
Type:boolean
bitbucketServerUrl (optional)
Type:String
checkoutCredentialsId (optional)
Type:String
credentialsId (optional)
Credentials used to scan branches (also the default credentials to use when checking out sources).

For security reasons most credentials are only available when HTTPS is used.

Type:String
excludes (optional)
Type:String
id (optional)
Type:String
includes (optional)
Type:String
serverUrl (optional)
The server to connect to.

The list of servers is configured in the Manage Jenkins » Configure Jenkins › Bitbucket Endpoints screen. The list of servers can include both Bitbucket Cloud and Bitbucket Server instances.

Type:String
traits (optional)
The behaviours control what is discovered from the Bitbucket repository. The behaviours are grouped into a number of categories:
Within repository
These behaviours determine what gets discovered. If you do not configure at least one discovery behaviour then nothing will be found!
General
These behaviours affect the configuration of each discovered branch / pull request.
Git
These behaviours affect the configuration of each discovered branch / pull request and are specific to Git semantics.
Array/List:
Nested choice of objects
$class: 'AuthorInChangelogTrait'
bitbucketBuildStatusNotifications
Configure the Bitbucket notifications.
disableNotificationForNotBuildJobs (optional)
Type:boolean
sendSuccessNotificationForUnstableBuild (optional)
Type:boolean
$class: 'CheckoutOptionTrait'
extension
Nested object
timeout
Specify a timeout (in minutes) for checkout.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
$class: 'CleanAfterCheckoutTrait'
extension
Nested object
Clean up the workspace after every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CleanBeforeCheckoutTrait'
extension
Nested object
Clean up the workspace before every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CleanMercurialSCMSourceTrait'
When this behaviour is present, each build will wipe any local modifications or untracked files in the repository checkout. This is often a convenient way to ensure that a build is not using any artifacts from earlier builds.
$class: 'CloneOptionTrait'
extension
Nested object
shallow
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
noTags
Deselect this to perform a clone without tags, saving time and disk space when you just want to access what is specified by the refspec.
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
Type:String
timeout
Specify a timeout (in minutes) for clone and fetch operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
honorRefspec (optional)
Perform initial clone using the refspec defined for the repository. This can save time, data transfer and disk space when you only need to access the references specified by the refspec.
Type:boolean
$class: 'DiscoverOtherRefsTrait'
Discovers other specified refs on the repository.
ref

The pattern under /refs on the remote repository to discover, can contain a wildcard.
Example: test/*/merged

Type:String
nameMapping (optional)

Mapping for how the ref can be named in for example the @Library.
Example: test-@{1}
Where @{1} replaces the first wildcard in the ref when discovered.

By default it will be "namespace_before_wildcard-@{1}". E.g. if ref is "test/*/merged" the default mapping would be "test-@{1}".

Type:String
$class: 'GitBrowserSCMSourceTrait'
browser
Nested choice of objects
$class: 'AssemblaWeb'
repoUrl
Specify the root URL serving this repository (such as https://www.assembla.com/code/PROJECT/git/).
Type:String
bitbucketServer
repoUrl
Specify the Bitbucket Server root URL for this repository (such as https://bitbucket:7990/OWNER/REPO/).
Type:String
$class: 'BitbucketWeb'
repoUrl
Specify the root URL serving this repository (such as https://bitbucket.org/OWNER/REPO/).
Type:String
$class: 'CGit'
repoUrl
Specify the root URL serving this repository (such as http://cgit.example.com:port/group/REPO/).
Type:String
$class: 'FisheyeGitRepositoryBrowser'
repoUrl
Specify the URL of this repository in FishEye (such as http://fisheye6.cenqua.com/browse/ant/).
Type:String
$class: 'GitBlitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository.
Type:String
projectName
Specify the name of the project in GitBlit.
Type:String
$class: 'GitLab'
repoUrl
Specify the root URL serving this repository (such as http://gitlabserver:port/group/REPO/).
Type:String
version (optional)
Specify the major and minor version of GitLab you use (such as 9.1). If you don't specify a version, a modern version of GitLab (>= 8.0) is assumed.
Type:String
$class: 'GitList'
repoUrl
Specify the root URL serving this repository (such as http://gitlistserver:port/REPO/).
Type:String
$class: 'GitWeb'
repoUrl
Specify the root URL serving this repository (such as https://github.com/jenkinsci/jenkins.git).
Type:String
$class: 'GithubWeb'
repoUrl
Specify the HTTP URL for this repository's GitHub page (such as https://github.com/jquery/jquery).
Type:String
$class: 'Gitiles'
repoUrl
Specify the root URL serving this repository (such as https://gwt.googlesource.com/gwt/).
Type:String
$class: 'GitoriousWeb'
repoUrl
Specify the root URL serving this repository (such as https://gitorious.org/gitorious/mainline).
Type:String
$class: 'GogsGit'
repoUrl
Specify the root URL serving this repository (such as http://gogs.example.com:port/username/some-repo-url.git).
Type:String
$class: 'KilnGit'
repoUrl
Specify the root URL serving this repository (such as https://khanacademy.kilnhg.com/Code/Website/Group/webapp).
Type:String
$class: 'Phabricator'
repoUrl
Specify the phabricator instance root URL (such as http://phabricator.example.com).
Type:String
repo
Specify the repository name in phabricator (such as the foo part of phabricator.example.com/diffusion/foo/browse).
Type:String
$class: 'RedmineWeb'
repoUrl
Specify the root URL serving this repository (such as http://SERVER/PATH/projects/PROJECT/repository).
Type:String
$class: 'RhodeCode'
repoUrl
Specify the HTTP URL for this repository's RhodeCode page (such as http://rhodecode.mydomain.com:5000/projects/PROJECT/repos/REPO/).
Type:String
$class: 'ScmManagerGitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository (such as https://scm-manager.org/scm/repo/namespace/name).
Type:String
$class: 'Stash'
repoUrl
Specify the HTTP URL for this repository's Stash page (such as http://stash.mydomain.com:7990/projects/PROJECT/repos/REPO/).
Type:String
$class: 'TFS2013GitRepositoryBrowser'
repoUrl
Either the name of the remote whose URL should be used, or the URL of this module in TFS (such as http://fisheye6.cenqua.com/tfs/PROJECT/_git/REPO/). If empty (default), the URL of the "origin" repository is used.

If TFS is also used as the repository server, this can usually be left blank.

Type:String
$class: 'ViewGitWeb'
repoUrl
Specify the root URL serving this repository (such as http://code.fealdia.org/viewgit/).
Type:String
projectName
Specify the name of the project in ViewGit (e.g. scripts, scuttle etc. from http://code.fealdia.org/viewgit/).
Type:String
$class: 'GitLFSPullTrait'
$class: 'GitToolSCMSourceTrait'
gitTool
Type:String
gitHubIgnoreDraftPullRequestFilter
$class: 'IgnoreOnPushNotificationTrait'
$class: 'LocalBranchTrait'
$class: 'MercurialBrowserSCMSourceTrait'
browser
Nested choice of objects
$class: 'FishEye'
url
Specify the root URL serving this repository, such as: http://www.example.org/browse/hg/
Type:String
$class: 'GoogleCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'HgWeb'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'Kallithea'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'KilnHG'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCodeLegacy'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'ScmManager'
url
Specify the root URL serving this repository (such as http://YOURSCMMANAGER/scm/repo/NAMESPACE/NAME/).
Type:String
$class: 'MercurialInstallationSCMSourceTrait'
installation
Type:String
$class: 'PruneStaleBranchTrait'
$class: 'PruneStaleTagTrait'
bitbucketPublicRepoPullRequestFilter
If the repository being scanned is a public repository, this behaviour will exclude all pull requests. (Note: This behaviour is not especially useful if scanning a single repository as you could just not include the pull request discovery behaviours in the first place)
$class: 'PullRequestDiscoveryTrait'
excludeBranchesWithPRs
Exclude branches for which there is an open pull request
Type:boolean
$class: 'RefSpecsSCMSourceTrait'
templates
Array/List:
Nested object
value
A ref spec to fetch. Any occurrences of @{remote} will be replaced by the remote name (which defaults to origin) before use.
Type:String
headRegexFilter
regex
A Java regular expression to restrict the names. Names that do not match the supplied regular expression will be ignored.
NOTE: this filter will be applied to all branch like things, including change requests
Type:String
$class: 'RemoteNameSCMSourceTrait'
remoteName
Type:String
$class: 'SparseCheckoutPathsTrait'
extension
Nested object

Specify the paths that you'd like to sparse checkout. This may be used for saving space (Think about a reference repository). Be sure to use a recent version of Git, at least above 1.7.10

sparseCheckoutPaths
Array/List:
Nested object
path
Type:String
$class: 'SubmoduleOptionTrait'
extension
Nested object
disableSubmodules
By disabling support for submodules you can still keep using basic git plugin functionality and just have Jenkins to ignore submodules completely as if they didn't exist.
Type:boolean
recursiveSubmodules
Retrieve all submodules recursively (uses '--recursive' option which requires git>=1.6.5)
Type:boolean
trackingSubmodules
Retrieve the tip of the configured branch in .gitmodules (Uses '--remote' option which requires git>=1.8.2)
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
To prepare a reference folder with multiple subprojects, create a bare git repository and add all the remote urls then perform a fetch:
  git init --bare
  git remote add SubProject1 https://gitrepo.com/subproject1
  git remote add SubProject2 https://gitrepo.com/subproject2
  git fetch --all
  
Type:String
timeout
Specify a timeout (in minutes) for submodules operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
parentCredentials
Use credentials from the default remote of the parent project.
Type:boolean
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
shallow (optional)
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
threads (optional)
Specify the number of threads that will be used to update submodules.
If unspecified, the command line git default thread count is used.
Type:int
$class: 'UserIdentityTrait'
extension
Nested object
name

If given, "GIT_COMMITTER_NAME=[this]" and "GIT_AUTHOR_NAME=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
email

If given, "GIT_COMMITTER_EMAIL=[this]" and "GIT_AUTHOR_EMAIL=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
bitbucketWebhookConfiguration

Sets the value for committersToIgnore in the Bitbucket Webhook. Value should be a comma separated string.

committerToIgnore is used to prevent triggering Jenkins builds when commits by certain users are made.

committersToIgnore
Type:String
bitbucketWebhookRegistration

Overrides the defaults for webhook management.

Webhooks are used to inform Jenkins about changes to repositories. There are two ways webhooks can be configured:

  • Manual webhook configuration requires the user to configure Bitbucket with the Jenkins URL in order to ensure that Bitbucket will send the events to Jenkins after every change.
  • Automatic webhook configuration requires that Jenkins has credentials with sufficient permission to configure webhooks and also that Jenkins knows the URL that Bitbucket can connect to.

The Manage Jenkins » Configure Jenkins › Bitbucket Endpoints allows defining the list of servers. Each server can be associated with credentials. If credentials are defined then the default behaviour is to use those credentials to automatically manage the webhooks of all repositories that Jenkins is interested in. If no credentials are defined then the default behaviour is to require the user to manually configure webhooks.

mode
There are two available modes:
Disable hook management
Disables hook management irrespective of the global defaults.
Use item credentials for hook management
Enabled hook management but uses the selected credentials to manage the hooks rather than those defined in Manage Jenkins » Configure Jenkins › Bitbucket Endpoints
Type:String
headWildcardFilter
includes
Space-separated list of name patterns to consider. You may use * as a wildcard; for example: master release*
NOTE: this filter will be applied to all branch like things, including change requests
Type:String
excludes
Space-separated list of name patterns to ignore even if matched by the includes list. For example: release alpha-* beta-*
NOTE: this filter will be applied to all branch like things, including change requests
Type:String
$class: 'WipeWorkspaceTrait'
bitbucketBranchDiscovery
Discovers branches on the repository.
strategyId
Determines which branches are discovered.
Exclude branches that are also filed as PRs
If you are discovering origin pull requests, it may not make sense to discover the same changes both as a pull request and as a branch.
Only branches that are also filed as PRs
Discovers branches that have PR's associated with them. This may make sense if you have a notification sent to the team at the end of a triggered build or limited Jenkins resources.
All branches
Ignores whether the branch is also filed as a pull request and instead discovers all branches on the origin repository.
Type:int
bitbucketForkDiscovery
Discovers pull requests where the origin repository is a fork of the target repository.
strategyId
Determines how pull requests are discovered.
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging
Type:int
trust

One of the great powers of pull requests is that anyone with read access to a repository can fork it, commit some changes to their fork and then create a pull request against the original repository with their changes. There are some files stored in source control that are important. For example, a Jenkinsfile may contain configuration details to sandbox pull requests in order to mitigate against malicious pull requests. In order to protect against a malicious pull request itself modifying the Jenkinsfile to remove the protections, you can define the trust policy for pull requests from forks.

Other plugins can extend the available trust policies. The default policies are:

Nobody
Pull requests from forks will all be treated as untrusted. This means that where Jenkins requires a trusted file (e.g. Jenkinsfile) the contents of that file will be retrieved from the target branch on the origin repository and not from the pull request branch on the fork repository.
Forks in the same account
Bitbucket allows for a repository to be forked into a "sibling" repository in the same account but using a different name. This strategy will trust any pull requests from forks that are in the same account as the target repository on the basis that users have to have been granted write permission to account in order create such a fork.
Everyone
All pull requests from forks will be treated as trusted. NOTE: this option can be dangerous if used on a public repository hosted on Bitbucket Cloud.
java.lang.UnsupportedOperationException: do not know how to categorize attributes of type jenkins.scm.api.trait.SCMHeadAuthority<? super com.cloudbees.jenkins.plugins.bitbucket.BitbucketSCMSourceRequest, ? extends jenkins.scm.api.mixin.ChangeRequestSCMHead2, ? extends jenkins.scm.api.SCMRevision>
bitbucketPullRequestDiscovery
Discovers pull requests where the origin repository is the same as the target repository.
strategyId
Determines how pull requests are discovered.
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging
Type:int
bitbucketSshCheckout
By default the discovered branches / pull requests will all use the same credentials that were used for discovery when checking out sources. This means that the checkout will be using the https:// protocol for the Git repository.

This behaviour allows you to select the SSH private key to be used for checking out sources, which will consequently force the checkout to use the ssh:// protocol.

credentialsId
Credentials used to check out sources.

It must be a SSH key based credential.

Type:String
bitbucketTagDiscovery
Discovers tags on the repository.
$class: 'com.cloudogu.scmmanager.scm.BranchDiscoveryTrait'
$class: 'com.cloudogu.scmmanager.scm.TagDiscoveryTrait'
gitBranchDiscovery
Discovers branches on the repository.
gitTagDiscovery
Discovers tags on the repository.
gitHubBranchDiscovery
Discovers branches on the repository.
strategyId
Determines which branches are discovered.
Exclude branches that are also filed as PRs
If you are discovering origin pull requests, you may not want to also build the source branches for those pull requests.
Only branches that are also filed as PRs
Similar to discovering origin pull requests, but discovers the branch rather than the pull request. This means env.GIT_BRANCH will be set to the branch name rather than PR-#. Also, status notifications for these builds will only be applied to the commit and not to the pull request.
All branches
Ignores whether the branch is also filed as a pull request and instead discovers all branches on the origin repository.
Type:int
gitHubForkDiscovery
Discovers pull requests where the origin repository is a fork of the target repository.
strategyId
Determines how pull requests are discovered:
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch.
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging.
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging.
Type:int
trust

One of the great powers of pull requests is that anyone with read access to a repository can fork it, commit some changes to their fork and then create a pull request against the original repository with their changes. There are some files stored in source control that are important. For example, a Jenkinsfile may contain configuration details to sandbox pull requests in order to mitigate against malicious pull requests. In order to protect against a malicious pull request itself modifying the Jenkinsfile to remove the protections, you can define the trust policy for pull requests from forks.

Other plugins can extend the available trust policies. The default policies are:

Nobody
Pull requests from forks will all be treated as untrusted. This means that where Jenkins requires a trusted file (e.g. Jenkinsfile) the contents of that file will be retrieved from the target branch on the origin repository and not from the pull request branch on the fork repository.
Collaborators
Pull requests from collaborators to the origin repository will be treated as trusted, all other pull requests from fork repositories will be treated as untrusted. Note that if credentials used by Jenkins for scanning the repository does not have permission to query the list of collaborators to the origin repository then only the origin account will be treated as trusted - i.e. this will fall back to Nobody. NOTE: all collaborators are trusted, even if they are only members of a team with read permission.
Everyone
All pull requests from forks will be treated as trusted. NOTE: this option can be dangerous if used on a public repository hosted on GitHub.
From users with Admin or Write permission
Pull requests forks will be treated as trusted if and only if the fork owner has either Admin or Write permissions on the origin repository. This is the recommended policy. Note that this strategy requires the Review a user's permission level API, as a result on GitHub Enterprise Server versions before 2.12 this is the same as trusting Nobody.
java.lang.UnsupportedOperationException: do not know how to categorize attributes of type jenkins.scm.api.trait.SCMHeadAuthority<? super org.jenkinsci.plugins.github_branch_source.GitHubSCMSourceRequest, ? extends jenkins.scm.api.mixin.ChangeRequestSCMHead2, ? extends jenkins.scm.api.SCMRevision>
gitHubPullRequestDiscovery
Discovers pull requests where the origin repository is the same as the target repository.
strategyId
Determines how pull requests are discovered:
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch.
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging.
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging.
Type:int
gitHubSshCheckout
By default the discovered branches / pull requests will all use the same username / password credentials that were used for discovery when checking out sources. This means that the checkout will be using the https:// protocol for the Git repository.

This behaviour allows you to select the SSH private key to be used for checking out sources, which will consequently force the checkout to use the ssh:// protocol.

credentialsId
Credentials used to check out sources. Must be a SSH key based credential.
Type:String
gitHubTagDiscovery
Discovers tags on the repository.
github
repoOwner

Specify the name of the GitHub Organization or GitHub User Account.

Type:String
repository
The repository to scan.
Type:String
repositoryUrl

Specify the HTTPS URL of the GitHub Organization / User Account and repository.

GitHub examples:

  • https://github.com/jenkinsci/github-branch-source-plugin
  • https://github.com/jenkinsci/github-branch-source-plugin.git

GitHub Enterprise examples:

  • https://myccompany.github.com/jenkinsci/github-branch-source-plugin
  • https://myccompany.github.com/jenkinsci/github-branch-source-plugin.git

Type:String
configuredByUrl
Type:boolean
apiUri (optional)
The server to connect to. The list of servers is configured in the Manage Jenkins » Configure System » GitHub Enterprise Servers screen.
Type:String
buildForkPRHead (optional)
Type:boolean
buildForkPRMerge (optional)
Type:boolean
buildOriginBranch (optional)
Type:boolean
buildOriginBranchWithPR (optional)
Type:boolean
buildOriginPRHead (optional)
Type:boolean
buildOriginPRMerge (optional)
Type:boolean
credentialsId (optional)

Credentials used to scan branches and pull requests, check out sources and mark commit statuses.

Note that only "username with password" credentials are supported. Existing credentials of other kinds will be filtered out. This is because Jenkins uses the GitHub API, which does not support other ways of authentication.

If none is given, only the public repositories will be scanned, and commit status will not be set on GitHub.

If your organization contains private repositories, then you need to specify a credential from a user who has access to those repositories. This is done by creating a "username with password" credential where the password is GitHub personal access tokens. The necessary scope is "repo".

Type:String
excludes (optional)
Type:String
id (optional)
Type:String
includes (optional)
Type:String
traits (optional)
The behaviours control what is discovered from the GitHub repository. The behaviours are grouped into a number of categories:
Within repository
These behaviours determine what gets discovered. If you do not configure at least one discovery behaviour then nothing will be found!
General
These behaviours affect the configuration of each discovered branch / pull request.
Array/List:
Nested choice of objects
$class: 'AuthorInChangelogTrait'
bitbucketBuildStatusNotifications
Configure the Bitbucket notifications.
disableNotificationForNotBuildJobs (optional)
Type:boolean
sendSuccessNotificationForUnstableBuild (optional)
Type:boolean
$class: 'CheckoutOptionTrait'
extension
Nested object
timeout
Specify a timeout (in minutes) for checkout.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
$class: 'CleanAfterCheckoutTrait'
extension
Nested object
Clean up the workspace after every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CleanBeforeCheckoutTrait'
extension
Nested object
Clean up the workspace before every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CleanMercurialSCMSourceTrait'
When this behaviour is present, each build will wipe any local modifications or untracked files in the repository checkout. This is often a convenient way to ensure that a build is not using any artifacts from earlier builds.
$class: 'CloneOptionTrait'
extension
Nested object
shallow
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
noTags
Deselect this to perform a clone without tags, saving time and disk space when you just want to access what is specified by the refspec.
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
Type:String
timeout
Specify a timeout (in minutes) for clone and fetch operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
honorRefspec (optional)
Perform initial clone using the refspec defined for the repository. This can save time, data transfer and disk space when you only need to access the references specified by the refspec.
Type:boolean
$class: 'DiscoverOtherRefsTrait'
Discovers other specified refs on the repository.
ref

The pattern under /refs on the remote repository to discover, can contain a wildcard.
Example: test/*/merged

Type:String
nameMapping (optional)

Mapping for how the ref can be named in for example the @Library.
Example: test-@{1}
Where @{1} replaces the first wildcard in the ref when discovered.

By default it will be "namespace_before_wildcard-@{1}". E.g. if ref is "test/*/merged" the default mapping would be "test-@{1}".

Type:String
$class: 'GitBrowserSCMSourceTrait'
browser
Nested choice of objects
$class: 'AssemblaWeb'
repoUrl
Specify the root URL serving this repository (such as https://www.assembla.com/code/PROJECT/git/).
Type:String
bitbucketServer
repoUrl
Specify the Bitbucket Server root URL for this repository (such as https://bitbucket:7990/OWNER/REPO/).
Type:String
$class: 'BitbucketWeb'
repoUrl
Specify the root URL serving this repository (such as https://bitbucket.org/OWNER/REPO/).
Type:String
$class: 'CGit'
repoUrl
Specify the root URL serving this repository (such as http://cgit.example.com:port/group/REPO/).
Type:String
$class: 'FisheyeGitRepositoryBrowser'
repoUrl
Specify the URL of this repository in FishEye (such as http://fisheye6.cenqua.com/browse/ant/).
Type:String
$class: 'GitBlitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository.
Type:String
projectName
Specify the name of the project in GitBlit.
Type:String
$class: 'GitLab'
repoUrl
Specify the root URL serving this repository (such as http://gitlabserver:port/group/REPO/).
Type:String
version (optional)
Specify the major and minor version of GitLab you use (such as 9.1). If you don't specify a version, a modern version of GitLab (>= 8.0) is assumed.
Type:String
$class: 'GitList'
repoUrl
Specify the root URL serving this repository (such as http://gitlistserver:port/REPO/).
Type:String
$class: 'GitWeb'
repoUrl
Specify the root URL serving this repository (such as https://github.com/jenkinsci/jenkins.git).
Type:String
$class: 'GithubWeb'
repoUrl
Specify the HTTP URL for this repository's GitHub page (such as https://github.com/jquery/jquery).
Type:String
$class: 'Gitiles'
repoUrl
Specify the root URL serving this repository (such as https://gwt.googlesource.com/gwt/).
Type:String
$class: 'GitoriousWeb'
repoUrl
Specify the root URL serving this repository (such as https://gitorious.org/gitorious/mainline).
Type:String
$class: 'GogsGit'
repoUrl
Specify the root URL serving this repository (such as http://gogs.example.com:port/username/some-repo-url.git).
Type:String
$class: 'KilnGit'
repoUrl
Specify the root URL serving this repository (such as https://khanacademy.kilnhg.com/Code/Website/Group/webapp).
Type:String
$class: 'Phabricator'
repoUrl
Specify the phabricator instance root URL (such as http://phabricator.example.com).
Type:String
repo
Specify the repository name in phabricator (such as the foo part of phabricator.example.com/diffusion/foo/browse).
Type:String
$class: 'RedmineWeb'
repoUrl
Specify the root URL serving this repository (such as http://SERVER/PATH/projects/PROJECT/repository).
Type:String
$class: 'RhodeCode'
repoUrl
Specify the HTTP URL for this repository's RhodeCode page (such as http://rhodecode.mydomain.com:5000/projects/PROJECT/repos/REPO/).
Type:String
$class: 'ScmManagerGitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository (such as https://scm-manager.org/scm/repo/namespace/name).
Type:String
$class: 'Stash'
repoUrl
Specify the HTTP URL for this repository's Stash page (such as http://stash.mydomain.com:7990/projects/PROJECT/repos/REPO/).
Type:String
$class: 'TFS2013GitRepositoryBrowser'
repoUrl
Either the name of the remote whose URL should be used, or the URL of this module in TFS (such as http://fisheye6.cenqua.com/tfs/PROJECT/_git/REPO/). If empty (default), the URL of the "origin" repository is used.

If TFS is also used as the repository server, this can usually be left blank.

Type:String
$class: 'ViewGitWeb'
repoUrl
Specify the root URL serving this repository (such as http://code.fealdia.org/viewgit/).
Type:String
projectName
Specify the name of the project in ViewGit (e.g. scripts, scuttle etc. from http://code.fealdia.org/viewgit/).
Type:String
$class: 'GitLFSPullTrait'
$class: 'GitToolSCMSourceTrait'
gitTool
Type:String
gitHubIgnoreDraftPullRequestFilter
$class: 'IgnoreOnPushNotificationTrait'
$class: 'LocalBranchTrait'
$class: 'MercurialBrowserSCMSourceTrait'
browser
Nested choice of objects
$class: 'FishEye'
url
Specify the root URL serving this repository, such as: http://www.example.org/browse/hg/
Type:String
$class: 'GoogleCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'HgWeb'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'Kallithea'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'KilnHG'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCodeLegacy'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'ScmManager'
url
Specify the root URL serving this repository (such as http://YOURSCMMANAGER/scm/repo/NAMESPACE/NAME/).
Type:String
$class: 'MercurialInstallationSCMSourceTrait'
installation
Type:String
$class: 'PruneStaleBranchTrait'
$class: 'PruneStaleTagTrait'
bitbucketPublicRepoPullRequestFilter
If the repository being scanned is a public repository, this behaviour will exclude all pull requests. (Note: This behaviour is not especially useful if scanning a single repository as you could just not include the pull request discovery behaviours in the first place)
$class: 'PullRequestDiscoveryTrait'
excludeBranchesWithPRs
Exclude branches for which there is an open pull request
Type:boolean
$class: 'RefSpecsSCMSourceTrait'
templates
Array/List:
Nested object
value
A ref spec to fetch. Any occurrences of @{remote} will be replaced by the remote name (which defaults to origin) before use.
Type:String
headRegexFilter
regex
A Java regular expression to restrict the names. Names that do not match the supplied regular expression will be ignored.
NOTE: this filter will be applied to all branch like things, including change requests
Type:String
$class: 'RemoteNameSCMSourceTrait'
remoteName
Type:String
$class: 'SparseCheckoutPathsTrait'
extension
Nested object

Specify the paths that you'd like to sparse checkout. This may be used for saving space (Think about a reference repository). Be sure to use a recent version of Git, at least above 1.7.10

sparseCheckoutPaths
Array/List:
Nested object
path
Type:String
$class: 'SubmoduleOptionTrait'
extension
Nested object
disableSubmodules
By disabling support for submodules you can still keep using basic git plugin functionality and just have Jenkins to ignore submodules completely as if they didn't exist.
Type:boolean
recursiveSubmodules
Retrieve all submodules recursively (uses '--recursive' option which requires git>=1.6.5)
Type:boolean
trackingSubmodules
Retrieve the tip of the configured branch in .gitmodules (Uses '--remote' option which requires git>=1.8.2)
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
To prepare a reference folder with multiple subprojects, create a bare git repository and add all the remote urls then perform a fetch:
  git init --bare
  git remote add SubProject1 https://gitrepo.com/subproject1
  git remote add SubProject2 https://gitrepo.com/subproject2
  git fetch --all
  
Type:String
timeout
Specify a timeout (in minutes) for submodules operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
parentCredentials
Use credentials from the default remote of the parent project.
Type:boolean
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
shallow (optional)
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
threads (optional)
Specify the number of threads that will be used to update submodules.
If unspecified, the command line git default thread count is used.
Type:int
$class: 'UserIdentityTrait'
extension
Nested object
name

If given, "GIT_COMMITTER_NAME=[this]" and "GIT_AUTHOR_NAME=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
email

If given, "GIT_COMMITTER_EMAIL=[this]" and "GIT_AUTHOR_EMAIL=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
bitbucketWebhookConfiguration

Sets the value for committersToIgnore in the Bitbucket Webhook. Value should be a comma separated string.

committerToIgnore is used to prevent triggering Jenkins builds when commits by certain users are made.

committersToIgnore
Type:String
bitbucketWebhookRegistration

Overrides the defaults for webhook management.

Webhooks are used to inform Jenkins about changes to repositories. There are two ways webhooks can be configured:

  • Manual webhook configuration requires the user to configure Bitbucket with the Jenkins URL in order to ensure that Bitbucket will send the events to Jenkins after every change.
  • Automatic webhook configuration requires that Jenkins has credentials with sufficient permission to configure webhooks and also that Jenkins knows the URL that Bitbucket can connect to.

The Manage Jenkins » Configure Jenkins › Bitbucket Endpoints allows defining the list of servers. Each server can be associated with credentials. If credentials are defined then the default behaviour is to use those credentials to automatically manage the webhooks of all repositories that Jenkins is interested in. If no credentials are defined then the default behaviour is to require the user to manually configure webhooks.

mode
There are two available modes:
Disable hook management
Disables hook management irrespective of the global defaults.
Use item credentials for hook management
Enabled hook management but uses the selected credentials to manage the hooks rather than those defined in Manage Jenkins » Configure Jenkins › Bitbucket Endpoints
Type:String
headWildcardFilter
includes
Space-separated list of name patterns to consider. You may use * as a wildcard; for example: master release*
NOTE: this filter will be applied to all branch like things, including change requests
Type:String
excludes
Space-separated list of name patterns to ignore even if matched by the includes list. For example: release alpha-* beta-*
NOTE: this filter will be applied to all branch like things, including change requests
Type:String
$class: 'WipeWorkspaceTrait'
bitbucketBranchDiscovery
Discovers branches on the repository.
strategyId
Determines which branches are discovered.
Exclude branches that are also filed as PRs
If you are discovering origin pull requests, it may not make sense to discover the same changes both as a pull request and as a branch.
Only branches that are also filed as PRs
Discovers branches that have PR's associated with them. This may make sense if you have a notification sent to the team at the end of a triggered build or limited Jenkins resources.
All branches
Ignores whether the branch is also filed as a pull request and instead discovers all branches on the origin repository.
Type:int
bitbucketForkDiscovery
Discovers pull requests where the origin repository is a fork of the target repository.
strategyId
Determines how pull requests are discovered.
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging
Type:int
trust

One of the great powers of pull requests is that anyone with read access to a repository can fork it, commit some changes to their fork and then create a pull request against the original repository with their changes. There are some files stored in source control that are important. For example, a Jenkinsfile may contain configuration details to sandbox pull requests in order to mitigate against malicious pull requests. In order to protect against a malicious pull request itself modifying the Jenkinsfile to remove the protections, you can define the trust policy for pull requests from forks.

Other plugins can extend the available trust policies. The default policies are:

Nobody
Pull requests from forks will all be treated as untrusted. This means that where Jenkins requires a trusted file (e.g. Jenkinsfile) the contents of that file will be retrieved from the target branch on the origin repository and not from the pull request branch on the fork repository.
Forks in the same account
Bitbucket allows for a repository to be forked into a "sibling" repository in the same account but using a different name. This strategy will trust any pull requests from forks that are in the same account as the target repository on the basis that users have to have been granted write permission to account in order create such a fork.
Everyone
All pull requests from forks will be treated as trusted. NOTE: this option can be dangerous if used on a public repository hosted on Bitbucket Cloud.
java.lang.UnsupportedOperationException: do not know how to categorize attributes of type jenkins.scm.api.trait.SCMHeadAuthority<? super com.cloudbees.jenkins.plugins.bitbucket.BitbucketSCMSourceRequest, ? extends jenkins.scm.api.mixin.ChangeRequestSCMHead2, ? extends jenkins.scm.api.SCMRevision>
bitbucketPullRequestDiscovery
Discovers pull requests where the origin repository is the same as the target repository.
strategyId
Determines how pull requests are discovered.
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging
Type:int
bitbucketSshCheckout
By default the discovered branches / pull requests will all use the same credentials that were used for discovery when checking out sources. This means that the checkout will be using the https:// protocol for the Git repository.

This behaviour allows you to select the SSH private key to be used for checking out sources, which will consequently force the checkout to use the ssh:// protocol.

credentialsId
Credentials used to check out sources.

It must be a SSH key based credential.

Type:String
bitbucketTagDiscovery
Discovers tags on the repository.
$class: 'com.cloudogu.scmmanager.scm.BranchDiscoveryTrait'
$class: 'com.cloudogu.scmmanager.scm.TagDiscoveryTrait'
gitBranchDiscovery
Discovers branches on the repository.
gitTagDiscovery
Discovers tags on the repository.
gitHubBranchDiscovery
Discovers branches on the repository.
strategyId
Determines which branches are discovered.
Exclude branches that are also filed as PRs
If you are discovering origin pull requests, you may not want to also build the source branches for those pull requests.
Only branches that are also filed as PRs
Similar to discovering origin pull requests, but discovers the branch rather than the pull request. This means env.GIT_BRANCH will be set to the branch name rather than PR-#. Also, status notifications for these builds will only be applied to the commit and not to the pull request.
All branches
Ignores whether the branch is also filed as a pull request and instead discovers all branches on the origin repository.
Type:int
gitHubForkDiscovery
Discovers pull requests where the origin repository is a fork of the target repository.
strategyId
Determines how pull requests are discovered:
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch.
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging.
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging.
Type:int
trust

One of the great powers of pull requests is that anyone with read access to a repository can fork it, commit some changes to their fork and then create a pull request against the original repository with their changes. There are some files stored in source control that are important. For example, a Jenkinsfile may contain configuration details to sandbox pull requests in order to mitigate against malicious pull requests. In order to protect against a malicious pull request itself modifying the Jenkinsfile to remove the protections, you can define the trust policy for pull requests from forks.

Other plugins can extend the available trust policies. The default policies are:

Nobody
Pull requests from forks will all be treated as untrusted. This means that where Jenkins requires a trusted file (e.g. Jenkinsfile) the contents of that file will be retrieved from the target branch on the origin repository and not from the pull request branch on the fork repository.
Collaborators
Pull requests from collaborators to the origin repository will be treated as trusted, all other pull requests from fork repositories will be treated as untrusted. Note that if credentials used by Jenkins for scanning the repository does not have permission to query the list of collaborators to the origin repository then only the origin account will be treated as trusted - i.e. this will fall back to Nobody. NOTE: all collaborators are trusted, even if they are only members of a team with read permission.
Everyone
All pull requests from forks will be treated as trusted. NOTE: this option can be dangerous if used on a public repository hosted on GitHub.
From users with Admin or Write permission
Pull requests forks will be treated as trusted if and only if the fork owner has either Admin or Write permissions on the origin repository. This is the recommended policy. Note that this strategy requires the Review a user's permission level API, as a result on GitHub Enterprise Server versions before 2.12 this is the same as trusting Nobody.
java.lang.UnsupportedOperationException: do not know how to categorize attributes of type jenkins.scm.api.trait.SCMHeadAuthority<? super org.jenkinsci.plugins.github_branch_source.GitHubSCMSourceRequest, ? extends jenkins.scm.api.mixin.ChangeRequestSCMHead2, ? extends jenkins.scm.api.SCMRevision>
gitHubPullRequestDiscovery
Discovers pull requests where the origin repository is the same as the target repository.
strategyId
Determines how pull requests are discovered:
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch.
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging.
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging.
Type:int
gitHubSshCheckout
By default the discovered branches / pull requests will all use the same username / password credentials that were used for discovery when checking out sources. This means that the checkout will be using the https:// protocol for the Git repository.

This behaviour allows you to select the SSH private key to be used for checking out sources, which will consequently force the checkout to use the ssh:// protocol.

credentialsId
Credentials used to check out sources. Must be a SSH key based credential.
Type:String
gitHubTagDiscovery
Discovers tags on the repository.
git
remote
Specify the URL of this remote repository. This uses the same syntax as your git clone command.
Type:String
browser (optional)
Nested choice of objects
$class: 'AssemblaWeb'
repoUrl
Specify the root URL serving this repository (such as https://www.assembla.com/code/PROJECT/git/).
Type:String
bitbucketServer
repoUrl
Specify the Bitbucket Server root URL for this repository (such as https://bitbucket:7990/OWNER/REPO/).
Type:String
$class: 'BitbucketWeb'
repoUrl
Specify the root URL serving this repository (such as https://bitbucket.org/OWNER/REPO/).
Type:String
$class: 'CGit'
repoUrl
Specify the root URL serving this repository (such as http://cgit.example.com:port/group/REPO/).
Type:String
$class: 'FisheyeGitRepositoryBrowser'
repoUrl
Specify the URL of this repository in FishEye (such as http://fisheye6.cenqua.com/browse/ant/).
Type:String
$class: 'GitBlitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository.
Type:String
projectName
Specify the name of the project in GitBlit.
Type:String
$class: 'GitLab'
repoUrl
Specify the root URL serving this repository (such as http://gitlabserver:port/group/REPO/).
Type:String
version (optional)
Specify the major and minor version of GitLab you use (such as 9.1). If you don't specify a version, a modern version of GitLab (>= 8.0) is assumed.
Type:String
$class: 'GitList'
repoUrl
Specify the root URL serving this repository (such as http://gitlistserver:port/REPO/).
Type:String
$class: 'GitWeb'
repoUrl
Specify the root URL serving this repository (such as https://github.com/jenkinsci/jenkins.git).
Type:String
$class: 'GithubWeb'
repoUrl
Specify the HTTP URL for this repository's GitHub page (such as https://github.com/jquery/jquery).
Type:String
$class: 'Gitiles'
repoUrl
Specify the root URL serving this repository (such as https://gwt.googlesource.com/gwt/).
Type:String
$class: 'GitoriousWeb'
repoUrl
Specify the root URL serving this repository (such as https://gitorious.org/gitorious/mainline).
Type:String
$class: 'GogsGit'
repoUrl
Specify the root URL serving this repository (such as http://gogs.example.com:port/username/some-repo-url.git).
Type:String
$class: 'KilnGit'
repoUrl
Specify the root URL serving this repository (such as https://khanacademy.kilnhg.com/Code/Website/Group/webapp).
Type:String
$class: 'Phabricator'
repoUrl
Specify the phabricator instance root URL (such as http://phabricator.example.com).
Type:String
repo
Specify the repository name in phabricator (such as the foo part of phabricator.example.com/diffusion/foo/browse).
Type:String
$class: 'RedmineWeb'
repoUrl
Specify the root URL serving this repository (such as http://SERVER/PATH/projects/PROJECT/repository).
Type:String
$class: 'RhodeCode'
repoUrl
Specify the HTTP URL for this repository's RhodeCode page (such as http://rhodecode.mydomain.com:5000/projects/PROJECT/repos/REPO/).
Type:String
$class: 'ScmManagerGitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository (such as https://scm-manager.org/scm/repo/namespace/name).
Type:String
$class: 'Stash'
repoUrl
Specify the HTTP URL for this repository's Stash page (such as http://stash.mydomain.com:7990/projects/PROJECT/repos/REPO/).
Type:String
$class: 'TFS2013GitRepositoryBrowser'
repoUrl
Either the name of the remote whose URL should be used, or the URL of this module in TFS (such as http://fisheye6.cenqua.com/tfs/PROJECT/_git/REPO/). If empty (default), the URL of the "origin" repository is used.

If TFS is also used as the repository server, this can usually be left blank.

Type:String
$class: 'ViewGitWeb'
repoUrl
Specify the root URL serving this repository (such as http://code.fealdia.org/viewgit/).
Type:String
projectName
Specify the name of the project in ViewGit (e.g. scripts, scuttle etc. from http://code.fealdia.org/viewgit/).
Type:String
credentialsId (optional)
Credentials used to scan branches and check out sources.
Type:String
extensions (optional)
Array/List:
Nested choice of objects
$class: 'AuthorInChangelog'
The default behavior is to use the Git commit's "Committer" value in Jenkins' build changesets. If this option is selected, the Git commit's "Author" value would be used instead.
$class: 'BuildChooserSetting'
When you are interested in using a job to build multiple heads (most typically multiple branches), you can choose how Jenkins choose what branches to build in what order.

This extension point in Jenkins is used by many other plugins to control the job to build specific commits. When you activate those plugins, you may see them installing a custom strategy here.

buildChooser
Nested choice of objects
$class: 'AncestryBuildChooser'
maximumAgeInDays
Type:int
ancestorCommitSha1
Type:String
$class: 'DefaultBuildChooser'
$class: 'InverseBuildChooser'
$class: 'BuildSingleRevisionOnly'
Disable scheduling for multiple candidate revisions.
If we have 3 branches:
----A--.---.--- B
         \-----C
jenkins would try to build (B) and (C).
This behaviour disables this and only builds one of them.
It is helpful to reduce the load of the Jenkins infrastructure when the SCM system like Bitbucket or GitHub should decide what commits to build.
$class: 'ChangelogToBranch'
This method calculates the changelog against the specified branch.
options
Nested object
compareRemote
Name of the repository, such as origin, that contains the branch you specify below.
Type:String
compareTarget
The name of the branch within the named repository to compare against.
Type:String
$class: 'CheckoutOption'
timeout
Specify a timeout (in minutes) for checkout.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
$class: 'CleanBeforeCheckout'
Clean up the workspace before every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CleanCheckout'
Clean up the workspace after every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CloneOption'
shallow
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
noTags
Deselect this to perform a clone without tags, saving time and disk space when you just want to access what is specified by the refspec.
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
Type:String
timeout
Specify a timeout (in minutes) for clone and fetch operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
honorRefspec (optional)
Perform initial clone using the refspec defined for the repository. This can save time, data transfer and disk space when you only need to access the references specified by the refspec.
Type:boolean
$class: 'DisableRemotePoll'
Git plugin uses git ls-remote polling mechanism by default when configured with a single branch (no wildcards!). This compare the latest built commit SHA with the remote branch without cloning a local copy of the repo.

If you don't want to / can't use this.

If this option is selected, polling will require a workspace and might trigger unwanted builds (see JENKINS-10131).
$class: 'GitLFSPull'
Enable git large file support for the workspace by pulling large files after the checkout completes. Requires that the controller and each agent performing an LFS checkout have installed `git lfs`.
$class: 'IgnoreNotifyCommit'
If checked, this repository will be ignored when the notifyCommit-URL is accessed regardless of if the repository matches or not.
$class: 'LocalBranch'
If given, checkout the revision to build as HEAD on this branch.

If selected, and its value is an empty string or "**", then the branch name is computed from the remote branch without the origin. In that case, a remote branch origin/master will be checked out to a local branch named master, and a remote branch origin/develop/new-feature will be checked out to a local branch named develop/newfeature.

Please note that this has not been tested with submodules.

localBranch
Type:String
$class: 'MessageExclusion'
excludedMessage
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions committed with message matched to Pattern when determining if a build needs to be triggered. This can be used to exclude commits done by the build itself from triggering another build, assuming the build server commits the change with a distinct message.

Exclusion uses Pattern matching

.*\[maven-release-plugin\].*
The example above illustrates that if only revisions with "[maven-release-plugin]" message in first comment line have been committed to the SCM a build will not occur.

You can create more complex patterns using embedded flag expressions.

(?s).*FOO.*
This example will search FOO message in all comment lines.
Type:String
$class: 'PathRestriction'
If set, and Jenkins is set to poll for changes, Jenkins will pay attention to included and/or excluded files and/or folders when determining if a build needs to be triggered.

Using this behaviour will preclude the faster git ls-remote polling mechanism, forcing polling to require a workspace thus sometimes triggering unwanted builds, as if you had selected the Force polling using workspace extension as well.

includedRegions
Each inclusion uses java regular expression pattern matching, and must be separated by a new line. An empty list implies that everything is included.

    myapp/src/main/web/.*\.html
    myapp/src/main/web/.*\.jpeg
    myapp/src/main/web/.*\.gif
  
The example above illustrates that a build will only occur, if html/jpeg/gif files have been committed to the SCM. Exclusions take precedence over inclusions, if there is an overlap between included and excluded regions.
Type:String
excludedRegions
Each exclusion uses java regular expression pattern matching, and must be separated by a new line.

    myapp/src/main/web/.*\.html
    myapp/src/main/web/.*\.jpeg
    myapp/src/main/web/.*\.gif
  
The example above illustrates that if only html/jpeg/gif files have been committed to the SCM a build will not occur.
Type:String
$class: 'PerBuildTag'
Create a tag in the workspace for every build to unambiguously mark the commit that was built. You can combine this with Git publisher to push the tags to the remote repository.
$class: 'PreBuildMerge'
These options allow you to perform a merge to a particular branch before building. For example, you could specify an integration branch to be built, and to merge to master. In this scenario, on every change of integration, Jenkins will perform a merge with the master branch, and try to perform a build if the merge is successful. It then may push the merge back to the remote repository if the Git Push post-build action is selected.
options
Nested object
mergeTarget
The name of the branch within the named repository to merge to, such as master.
Type:String
fastForwardMode (optional)
Merge fast-forward mode selection.
The default, --ff, gracefully falls back to a merge commit when required.
For more information, see the Git Merge Documentation
Values:
FF
FF_ONLY
NO_FF
mergeRemote (optional)
Name of the repository, such as origin, that contains the branch you specify below. If left blank, it'll default to the name of the first repository configured above.
Type:String
mergeStrategy (optional)
Merge strategy selection. This feature is not fully implemented in JGIT.
Values:
DEFAULT
RESOLVE
RECURSIVE
OCTOPUS
OURS
SUBTREE
RECURSIVE_THEIRS
$class: 'PruneStaleBranch'
Run "git remote prune" for each remote, to prune obsolete local branches.
pruneTags
pruneTags
Type:boolean
$class: 'RelativeTargetDirectory'
relativeTargetDir
Specify a local directory (relative to the workspace root) where the Git repository will be checked out. If left empty, the workspace root itself will be used.

This extension should not be used in Jenkins Pipeline (either declarative or scripted). Jenkins Pipeline already provides standard techniques for checkout to a subdirectory. Use ws and dir in Jenkins Pipeline rather than this extension.

Type:String
$class: 'ScmName'

Unique name for this SCM. Needed when using Git within the Multi SCM plugin.

name
Type:String
$class: 'SparseCheckoutPaths'

Specify the paths that you'd like to sparse checkout. This may be used for saving space (Think about a reference repository). Be sure to use a recent version of Git, at least above 1.7.10

sparseCheckoutPaths
Array/List:
Nested object
path
Type:String
$class: 'SubmoduleOption'
disableSubmodules
By disabling support for submodules you can still keep using basic git plugin functionality and just have Jenkins to ignore submodules completely as if they didn't exist.
Type:boolean
recursiveSubmodules
Retrieve all submodules recursively (uses '--recursive' option which requires git>=1.6.5)
Type:boolean
trackingSubmodules
Retrieve the tip of the configured branch in .gitmodules (Uses '--remote' option which requires git>=1.8.2)
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
To prepare a reference folder with multiple subprojects, create a bare git repository and add all the remote urls then perform a fetch:
  git init --bare
  git remote add SubProject1 https://gitrepo.com/subproject1
  git remote add SubProject2 https://gitrepo.com/subproject2
  git fetch --all
  
Type:String
timeout
Specify a timeout (in minutes) for submodules operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
parentCredentials
Use credentials from the default remote of the parent project.
Type:boolean
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
shallow (optional)
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
threads (optional)
Specify the number of threads that will be used to update submodules.
If unspecified, the command line git default thread count is used.
Type:int
$class: 'UserExclusion'
excludedUsers
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions committed by users in this list when determining if a build needs to be triggered. This can be used to exclude commits done by the build itself from triggering another build, assuming the build server commits the change with a distinct SCM user.

Using this behaviour will preclude the faster git ls-remote polling mechanism, forcing polling to require a workspace thus sometimes triggering unwanted builds, as if you had selected the Force polling using workspace extension as well.

Each exclusion uses exact string comparison and must be separated by a new line. User names are only excluded if they exactly match one of the names in this list.

auto_build_user
The example above illustrates that if only revisions by "auto_build_user" have been committed to the SCM a build will not occur.
Type:String
$class: 'UserIdentity'
name

If given, "GIT_COMMITTER_NAME=[this]" and "GIT_AUTHOR_NAME=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
email

If given, "GIT_COMMITTER_EMAIL=[this]" and "GIT_AUTHOR_EMAIL=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
$class: 'WipeWorkspace'
Delete the contents of the workspace before building, ensuring a fully fresh workspace.
gitTool (optional)
Type:String
id (optional)
Type:String
traits (optional)
Array/List:
Nested choice of objects
$class: 'AuthorInChangelogTrait'
bitbucketBuildStatusNotifications
Configure the Bitbucket notifications.
disableNotificationForNotBuildJobs (optional)
Type:boolean
sendSuccessNotificationForUnstableBuild (optional)
Type:boolean
$class: 'CheckoutOptionTrait'
extension
Nested object
timeout
Specify a timeout (in minutes) for checkout.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
$class: 'CleanAfterCheckoutTrait'
extension
Nested object
Clean up the workspace after every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CleanBeforeCheckoutTrait'
extension
Nested object
Clean up the workspace before every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CleanMercurialSCMSourceTrait'
When this behaviour is present, each build will wipe any local modifications or untracked files in the repository checkout. This is often a convenient way to ensure that a build is not using any artifacts from earlier builds.
$class: 'CloneOptionTrait'
extension
Nested object
shallow
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
noTags
Deselect this to perform a clone without tags, saving time and disk space when you just want to access what is specified by the refspec.
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
Type:String
timeout
Specify a timeout (in minutes) for clone and fetch operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
honorRefspec (optional)
Perform initial clone using the refspec defined for the repository. This can save time, data transfer and disk space when you only need to access the references specified by the refspec.
Type:boolean
$class: 'DiscoverOtherRefsTrait'
Discovers other specified refs on the repository.
ref

The pattern under /refs on the remote repository to discover, can contain a wildcard.
Example: test/*/merged

Type:String
nameMapping (optional)

Mapping for how the ref can be named in for example the @Library.
Example: test-@{1}
Where @{1} replaces the first wildcard in the ref when discovered.

By default it will be "namespace_before_wildcard-@{1}". E.g. if ref is "test/*/merged" the default mapping would be "test-@{1}".

Type:String
$class: 'GitBrowserSCMSourceTrait'
browser
Nested choice of objects
$class: 'AssemblaWeb'
repoUrl
Specify the root URL serving this repository (such as https://www.assembla.com/code/PROJECT/git/).
Type:String
bitbucketServer
repoUrl
Specify the Bitbucket Server root URL for this repository (such as https://bitbucket:7990/OWNER/REPO/).
Type:String
$class: 'BitbucketWeb'
repoUrl
Specify the root URL serving this repository (such as https://bitbucket.org/OWNER/REPO/).
Type:String
$class: 'CGit'
repoUrl
Specify the root URL serving this repository (such as http://cgit.example.com:port/group/REPO/).
Type:String
$class: 'FisheyeGitRepositoryBrowser'
repoUrl
Specify the URL of this repository in FishEye (such as http://fisheye6.cenqua.com/browse/ant/).
Type:String
$class: 'GitBlitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository.
Type:String
projectName
Specify the name of the project in GitBlit.
Type:String
$class: 'GitLab'
repoUrl
Specify the root URL serving this repository (such as http://gitlabserver:port/group/REPO/).
Type:String
version (optional)
Specify the major and minor version of GitLab you use (such as 9.1). If you don't specify a version, a modern version of GitLab (>= 8.0) is assumed.
Type:String
$class: 'GitList'
repoUrl
Specify the root URL serving this repository (such as http://gitlistserver:port/REPO/).
Type:String
$class: 'GitWeb'
repoUrl
Specify the root URL serving this repository (such as https://github.com/jenkinsci/jenkins.git).
Type:String
$class: 'GithubWeb'
repoUrl
Specify the HTTP URL for this repository's GitHub page (such as https://github.com/jquery/jquery).
Type:String
$class: 'Gitiles'
repoUrl
Specify the root URL serving this repository (such as https://gwt.googlesource.com/gwt/).
Type:String
$class: 'GitoriousWeb'
repoUrl
Specify the root URL serving this repository (such as https://gitorious.org/gitorious/mainline).
Type:String
$class: 'GogsGit'
repoUrl
Specify the root URL serving this repository (such as http://gogs.example.com:port/username/some-repo-url.git).
Type:String
$class: 'KilnGit'
repoUrl
Specify the root URL serving this repository (such as https://khanacademy.kilnhg.com/Code/Website/Group/webapp).
Type:String
$class: 'Phabricator'
repoUrl
Specify the phabricator instance root URL (such as http://phabricator.example.com).
Type:String
repo
Specify the repository name in phabricator (such as the foo part of phabricator.example.com/diffusion/foo/browse).
Type:String
$class: 'RedmineWeb'
repoUrl
Specify the root URL serving this repository (such as http://SERVER/PATH/projects/PROJECT/repository).
Type:String
$class: 'RhodeCode'
repoUrl
Specify the HTTP URL for this repository's RhodeCode page (such as http://rhodecode.mydomain.com:5000/projects/PROJECT/repos/REPO/).
Type:String
$class: 'ScmManagerGitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository (such as https://scm-manager.org/scm/repo/namespace/name).
Type:String
$class: 'Stash'
repoUrl
Specify the HTTP URL for this repository's Stash page (such as http://stash.mydomain.com:7990/projects/PROJECT/repos/REPO/).
Type:String
$class: 'TFS2013GitRepositoryBrowser'
repoUrl
Either the name of the remote whose URL should be used, or the URL of this module in TFS (such as http://fisheye6.cenqua.com/tfs/PROJECT/_git/REPO/). If empty (default), the URL of the "origin" repository is used.

If TFS is also used as the repository server, this can usually be left blank.

Type:String
$class: 'ViewGitWeb'
repoUrl
Specify the root URL serving this repository (such as http://code.fealdia.org/viewgit/).
Type:String
projectName
Specify the name of the project in ViewGit (e.g. scripts, scuttle etc. from http://code.fealdia.org/viewgit/).
Type:String
$class: 'GitLFSPullTrait'
$class: 'GitToolSCMSourceTrait'
gitTool
Type:String
gitHubIgnoreDraftPullRequestFilter
$class: 'IgnoreOnPushNotificationTrait'
$class: 'LocalBranchTrait'
$class: 'MercurialBrowserSCMSourceTrait'
browser
Nested choice of objects
$class: 'FishEye'
url
Specify the root URL serving this repository, such as: http://www.example.org/browse/hg/
Type:String
$class: 'GoogleCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'HgWeb'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'Kallithea'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'KilnHG'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCodeLegacy'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'ScmManager'
url
Specify the root URL serving this repository (such as http://YOURSCMMANAGER/scm/repo/NAMESPACE/NAME/).
Type:String
$class: 'MercurialInstallationSCMSourceTrait'
installation
Type:String
$class: 'PruneStaleBranchTrait'
$class: 'PruneStaleTagTrait'
bitbucketPublicRepoPullRequestFilter
If the repository being scanned is a public repository, this behaviour will exclude all pull requests. (Note: This behaviour is not especially useful if scanning a single repository as you could just not include the pull request discovery behaviours in the first place)
$class: 'PullRequestDiscoveryTrait'
excludeBranchesWithPRs
Exclude branches for which there is an open pull request
Type:boolean
$class: 'RefSpecsSCMSourceTrait'
templates
Array/List:
Nested object
value
A ref spec to fetch. Any occurrences of @{remote} will be replaced by the remote name (which defaults to origin) before use.
Type:String
headRegexFilter
regex
A Java regular expression to restrict the names. Names that do not match the supplied regular expression will be ignored.
NOTE: this filter will be applied to all branch like things, including change requests
Type:String
$class: 'RemoteNameSCMSourceTrait'
remoteName
Type:String
$class: 'SparseCheckoutPathsTrait'
extension
Nested object

Specify the paths that you'd like to sparse checkout. This may be used for saving space (Think about a reference repository). Be sure to use a recent version of Git, at least above 1.7.10

sparseCheckoutPaths
Array/List:
Nested object
path
Type:String
$class: 'SubmoduleOptionTrait'
extension
Nested object
disableSubmodules
By disabling support for submodules you can still keep using basic git plugin functionality and just have Jenkins to ignore submodules completely as if they didn't exist.
Type:boolean
recursiveSubmodules
Retrieve all submodules recursively (uses '--recursive' option which requires git>=1.6.5)
Type:boolean
trackingSubmodules
Retrieve the tip of the configured branch in .gitmodules (Uses '--remote' option which requires git>=1.8.2)
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
To prepare a reference folder with multiple subprojects, create a bare git repository and add all the remote urls then perform a fetch:
  git init --bare
  git remote add SubProject1 https://gitrepo.com/subproject1
  git remote add SubProject2 https://gitrepo.com/subproject2
  git fetch --all
  
Type:String
timeout
Specify a timeout (in minutes) for submodules operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
parentCredentials
Use credentials from the default remote of the parent project.
Type:boolean
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
shallow (optional)
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
threads (optional)
Specify the number of threads that will be used to update submodules.
If unspecified, the command line git default thread count is used.
Type:int
$class: 'UserIdentityTrait'
extension
Nested object
name

If given, "GIT_COMMITTER_NAME=[this]" and "GIT_AUTHOR_NAME=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
email

If given, "GIT_COMMITTER_EMAIL=[this]" and "GIT_AUTHOR_EMAIL=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
bitbucketWebhookConfiguration

Sets the value for committersToIgnore in the Bitbucket Webhook. Value should be a comma separated string.

committerToIgnore is used to prevent triggering Jenkins builds when commits by certain users are made.

committersToIgnore
Type:String
bitbucketWebhookRegistration

Overrides the defaults for webhook management.

Webhooks are used to inform Jenkins about changes to repositories. There are two ways webhooks can be configured:

  • Manual webhook configuration requires the user to configure Bitbucket with the Jenkins URL in order to ensure that Bitbucket will send the events to Jenkins after every change.
  • Automatic webhook configuration requires that Jenkins has credentials with sufficient permission to configure webhooks and also that Jenkins knows the URL that Bitbucket can connect to.

The Manage Jenkins » Configure Jenkins › Bitbucket Endpoints allows defining the list of servers. Each server can be associated with credentials. If credentials are defined then the default behaviour is to use those credentials to automatically manage the webhooks of all repositories that Jenkins is interested in. If no credentials are defined then the default behaviour is to require the user to manually configure webhooks.

mode
There are two available modes:
Disable hook management
Disables hook management irrespective of the global defaults.
Use item credentials for hook management
Enabled hook management but uses the selected credentials to manage the hooks rather than those defined in Manage Jenkins » Configure Jenkins › Bitbucket Endpoints
Type:String
headWildcardFilter
includes
Space-separated list of name patterns to consider. You may use * as a wildcard; for example: master release*
NOTE: this filter will be applied to all branch like things, including change requests
Type:String
excludes
Space-separated list of name patterns to ignore even if matched by the includes list. For example: release alpha-* beta-*
NOTE: this filter will be applied to all branch like things, including change requests
Type:String
$class: 'WipeWorkspaceTrait'
bitbucketBranchDiscovery
Discovers branches on the repository.
strategyId
Determines which branches are discovered.
Exclude branches that are also filed as PRs
If you are discovering origin pull requests, it may not make sense to discover the same changes both as a pull request and as a branch.
Only branches that are also filed as PRs
Discovers branches that have PR's associated with them. This may make sense if you have a notification sent to the team at the end of a triggered build or limited Jenkins resources.
All branches
Ignores whether the branch is also filed as a pull request and instead discovers all branches on the origin repository.
Type:int
bitbucketForkDiscovery
Discovers pull requests where the origin repository is a fork of the target repository.
strategyId
Determines how pull requests are discovered.
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging
Type:int
trust

One of the great powers of pull requests is that anyone with read access to a repository can fork it, commit some changes to their fork and then create a pull request against the original repository with their changes. There are some files stored in source control that are important. For example, a Jenkinsfile may contain configuration details to sandbox pull requests in order to mitigate against malicious pull requests. In order to protect against a malicious pull request itself modifying the Jenkinsfile to remove the protections, you can define the trust policy for pull requests from forks.

Other plugins can extend the available trust policies. The default policies are:

Nobody
Pull requests from forks will all be treated as untrusted. This means that where Jenkins requires a trusted file (e.g. Jenkinsfile) the contents of that file will be retrieved from the target branch on the origin repository and not from the pull request branch on the fork repository.
Forks in the same account
Bitbucket allows for a repository to be forked into a "sibling" repository in the same account but using a different name. This strategy will trust any pull requests from forks that are in the same account as the target repository on the basis that users have to have been granted write permission to account in order create such a fork.
Everyone
All pull requests from forks will be treated as trusted. NOTE: this option can be dangerous if used on a public repository hosted on Bitbucket Cloud.
java.lang.UnsupportedOperationException: do not know how to categorize attributes of type jenkins.scm.api.trait.SCMHeadAuthority<? super com.cloudbees.jenkins.plugins.bitbucket.BitbucketSCMSourceRequest, ? extends jenkins.scm.api.mixin.ChangeRequestSCMHead2, ? extends jenkins.scm.api.SCMRevision>
bitbucketPullRequestDiscovery
Discovers pull requests where the origin repository is the same as the target repository.
strategyId
Determines how pull requests are discovered.
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging
Type:int
bitbucketSshCheckout
By default the discovered branches / pull requests will all use the same credentials that were used for discovery when checking out sources. This means that the checkout will be using the https:// protocol for the Git repository.

This behaviour allows you to select the SSH private key to be used for checking out sources, which will consequently force the checkout to use the ssh:// protocol.

credentialsId
Credentials used to check out sources.

It must be a SSH key based credential.

Type:String
bitbucketTagDiscovery
Discovers tags on the repository.
$class: 'com.cloudogu.scmmanager.scm.BranchDiscoveryTrait'
$class: 'com.cloudogu.scmmanager.scm.TagDiscoveryTrait'
gitBranchDiscovery
Discovers branches on the repository.
gitTagDiscovery
Discovers tags on the repository.
gitHubBranchDiscovery
Discovers branches on the repository.
strategyId
Determines which branches are discovered.
Exclude branches that are also filed as PRs
If you are discovering origin pull requests, you may not want to also build the source branches for those pull requests.
Only branches that are also filed as PRs
Similar to discovering origin pull requests, but discovers the branch rather than the pull request. This means env.GIT_BRANCH will be set to the branch name rather than PR-#. Also, status notifications for these builds will only be applied to the commit and not to the pull request.
All branches
Ignores whether the branch is also filed as a pull request and instead discovers all branches on the origin repository.
Type:int
gitHubForkDiscovery
Discovers pull requests where the origin repository is a fork of the target repository.
strategyId
Determines how pull requests are discovered:
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch.
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging.
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging.
Type:int
trust

One of the great powers of pull requests is that anyone with read access to a repository can fork it, commit some changes to their fork and then create a pull request against the original repository with their changes. There are some files stored in source control that are important. For example, a Jenkinsfile may contain configuration details to sandbox pull requests in order to mitigate against malicious pull requests. In order to protect against a malicious pull request itself modifying the Jenkinsfile to remove the protections, you can define the trust policy for pull requests from forks.

Other plugins can extend the available trust policies. The default policies are:

Nobody
Pull requests from forks will all be treated as untrusted. This means that where Jenkins requires a trusted file (e.g. Jenkinsfile) the contents of that file will be retrieved from the target branch on the origin repository and not from the pull request branch on the fork repository.
Collaborators
Pull requests from collaborators to the origin repository will be treated as trusted, all other pull requests from fork repositories will be treated as untrusted. Note that if credentials used by Jenkins for scanning the repository does not have permission to query the list of collaborators to the origin repository then only the origin account will be treated as trusted - i.e. this will fall back to Nobody. NOTE: all collaborators are trusted, even if they are only members of a team with read permission.
Everyone
All pull requests from forks will be treated as trusted. NOTE: this option can be dangerous if used on a public repository hosted on GitHub.
From users with Admin or Write permission
Pull requests forks will be treated as trusted if and only if the fork owner has either Admin or Write permissions on the origin repository. This is the recommended policy. Note that this strategy requires the Review a user's permission level API, as a result on GitHub Enterprise Server versions before 2.12 this is the same as trusting Nobody.
java.lang.UnsupportedOperationException: do not know how to categorize attributes of type jenkins.scm.api.trait.SCMHeadAuthority<? super org.jenkinsci.plugins.github_branch_source.GitHubSCMSourceRequest, ? extends jenkins.scm.api.mixin.ChangeRequestSCMHead2, ? extends jenkins.scm.api.SCMRevision>
gitHubPullRequestDiscovery
Discovers pull requests where the origin repository is the same as the target repository.
strategyId
Determines how pull requests are discovered:
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch.
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging.
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging.
Type:int
gitHubSshCheckout
By default the discovered branches / pull requests will all use the same username / password credentials that were used for discovery when checking out sources. This means that the checkout will be using the https:// protocol for the Git repository.

This behaviour allows you to select the SSH private key to be used for checking out sources, which will consequently force the checkout to use the ssh:// protocol.

credentialsId
Credentials used to check out sources. Must be a SSH key based credential.
Type:String
gitHubTagDiscovery
Discovers tags on the repository.
$class: 'MercurialSCMSource'
source
Specify the repository to track. This can be URL or a local file path. If you are specifying HTTP credentials, do not include a username in the URL.
Type:String
credentialsId (optional)
Optional credentials to use when cloning or pulling from the remote repository. Supports username/password with HTTP(S) URLs, and SSH private key with SSH URLs.
Type:String
id (optional)
Type:String
traits (optional)
Array/List:
Nested choice of objects
$class: 'AuthorInChangelogTrait'
bitbucketBuildStatusNotifications
Configure the Bitbucket notifications.
disableNotificationForNotBuildJobs (optional)
Type:boolean
sendSuccessNotificationForUnstableBuild (optional)
Type:boolean
$class: 'CheckoutOptionTrait'
extension
Nested object
timeout
Specify a timeout (in minutes) for checkout.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
$class: 'CleanAfterCheckoutTrait'
extension
Nested object
Clean up the workspace after every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CleanBeforeCheckoutTrait'
extension
Nested object
Clean up the workspace before every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CleanMercurialSCMSourceTrait'
When this behaviour is present, each build will wipe any local modifications or untracked files in the repository checkout. This is often a convenient way to ensure that a build is not using any artifacts from earlier builds.
$class: 'CloneOptionTrait'
extension
Nested object
shallow
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
noTags
Deselect this to perform a clone without tags, saving time and disk space when you just want to access what is specified by the refspec.
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
Type:String
timeout
Specify a timeout (in minutes) for clone and fetch operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
honorRefspec (optional)
Perform initial clone using the refspec defined for the repository. This can save time, data transfer and disk space when you only need to access the references specified by the refspec.
Type:boolean
$class: 'DiscoverOtherRefsTrait'
Discovers other specified refs on the repository.
ref

The pattern under /refs on the remote repository to discover, can contain a wildcard.
Example: test/*/merged

Type:String
nameMapping (optional)

Mapping for how the ref can be named in for example the @Library.
Example: test-@{1}
Where @{1} replaces the first wildcard in the ref when discovered.

By default it will be "namespace_before_wildcard-@{1}". E.g. if ref is "test/*/merged" the default mapping would be "test-@{1}".

Type:String
$class: 'GitBrowserSCMSourceTrait'
browser
Nested choice of objects
$class: 'AssemblaWeb'
repoUrl
Specify the root URL serving this repository (such as https://www.assembla.com/code/PROJECT/git/).
Type:String
bitbucketServer
repoUrl
Specify the Bitbucket Server root URL for this repository (such as https://bitbucket:7990/OWNER/REPO/).
Type:String
$class: 'BitbucketWeb'
repoUrl
Specify the root URL serving this repository (such as https://bitbucket.org/OWNER/REPO/).
Type:String
$class: 'CGit'
repoUrl
Specify the root URL serving this repository (such as http://cgit.example.com:port/group/REPO/).
Type:String
$class: 'FisheyeGitRepositoryBrowser'
repoUrl
Specify the URL of this repository in FishEye (such as http://fisheye6.cenqua.com/browse/ant/).
Type:String
$class: 'GitBlitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository.
Type:String
projectName
Specify the name of the project in GitBlit.
Type:String
$class: 'GitLab'
repoUrl
Specify the root URL serving this repository (such as http://gitlabserver:port/group/REPO/).
Type:String
version (optional)
Specify the major and minor version of GitLab you use (such as 9.1). If you don't specify a version, a modern version of GitLab (>= 8.0) is assumed.
Type:String
$class: 'GitList'
repoUrl
Specify the root URL serving this repository (such as http://gitlistserver:port/REPO/).
Type:String
$class: 'GitWeb'
repoUrl
Specify the root URL serving this repository (such as https://github.com/jenkinsci/jenkins.git).
Type:String
$class: 'GithubWeb'
repoUrl
Specify the HTTP URL for this repository's GitHub page (such as https://github.com/jquery/jquery).
Type:String
$class: 'Gitiles'
repoUrl
Specify the root URL serving this repository (such as https://gwt.googlesource.com/gwt/).
Type:String
$class: 'GitoriousWeb'
repoUrl
Specify the root URL serving this repository (such as https://gitorious.org/gitorious/mainline).
Type:String
$class: 'GogsGit'
repoUrl
Specify the root URL serving this repository (such as http://gogs.example.com:port/username/some-repo-url.git).
Type:String
$class: 'KilnGit'
repoUrl
Specify the root URL serving this repository (such as https://khanacademy.kilnhg.com/Code/Website/Group/webapp).
Type:String
$class: 'Phabricator'
repoUrl
Specify the phabricator instance root URL (such as http://phabricator.example.com).
Type:String
repo
Specify the repository name in phabricator (such as the foo part of phabricator.example.com/diffusion/foo/browse).
Type:String
$class: 'RedmineWeb'
repoUrl
Specify the root URL serving this repository (such as http://SERVER/PATH/projects/PROJECT/repository).
Type:String
$class: 'RhodeCode'
repoUrl
Specify the HTTP URL for this repository's RhodeCode page (such as http://rhodecode.mydomain.com:5000/projects/PROJECT/repos/REPO/).
Type:String
$class: 'ScmManagerGitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository (such as https://scm-manager.org/scm/repo/namespace/name).
Type:String
$class: 'Stash'
repoUrl
Specify the HTTP URL for this repository's Stash page (such as http://stash.mydomain.com:7990/projects/PROJECT/repos/REPO/).
Type:String
$class: 'TFS2013GitRepositoryBrowser'
repoUrl
Either the name of the remote whose URL should be used, or the URL of this module in TFS (such as http://fisheye6.cenqua.com/tfs/PROJECT/_git/REPO/). If empty (default), the URL of the "origin" repository is used.

If TFS is also used as the repository server, this can usually be left blank.

Type:String
$class: 'ViewGitWeb'
repoUrl
Specify the root URL serving this repository (such as http://code.fealdia.org/viewgit/).
Type:String
projectName
Specify the name of the project in ViewGit (e.g. scripts, scuttle etc. from http://code.fealdia.org/viewgit/).
Type:String
$class: 'GitLFSPullTrait'
$class: 'GitToolSCMSourceTrait'
gitTool
Type:String
gitHubIgnoreDraftPullRequestFilter
$class: 'IgnoreOnPushNotificationTrait'
$class: 'LocalBranchTrait'
$class: 'MercurialBrowserSCMSourceTrait'
browser
Nested choice of objects
$class: 'FishEye'
url
Specify the root URL serving this repository, such as: http://www.example.org/browse/hg/
Type:String
$class: 'GoogleCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'HgWeb'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'Kallithea'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'KilnHG'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCodeLegacy'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'ScmManager'
url
Specify the root URL serving this repository (such as http://YOURSCMMANAGER/scm/repo/NAMESPACE/NAME/).
Type:String
$class: 'MercurialInstallationSCMSourceTrait'
installation
Type:String
$class: 'PruneStaleBranchTrait'
$class: 'PruneStaleTagTrait'
bitbucketPublicRepoPullRequestFilter
If the repository being scanned is a public repository, this behaviour will exclude all pull requests. (Note: This behaviour is not especially useful if scanning a single repository as you could just not include the pull request discovery behaviours in the first place)
$class: 'PullRequestDiscoveryTrait'
excludeBranchesWithPRs
Exclude branches for which there is an open pull request
Type:boolean
$class: 'RefSpecsSCMSourceTrait'
templates
Array/List:
Nested object
value
A ref spec to fetch. Any occurrences of @{remote} will be replaced by the remote name (which defaults to origin) before use.
Type:String
headRegexFilter
regex
A Java regular expression to restrict the names. Names that do not match the supplied regular expression will be ignored.
NOTE: this filter will be applied to all branch like things, including change requests
Type:String
$class: 'RemoteNameSCMSourceTrait'
remoteName
Type:String
$class: 'SparseCheckoutPathsTrait'
extension
Nested object

Specify the paths that you'd like to sparse checkout. This may be used for saving space (Think about a reference repository). Be sure to use a recent version of Git, at least above 1.7.10

sparseCheckoutPaths
Array/List:
Nested object
path
Type:String
$class: 'SubmoduleOptionTrait'
extension
Nested object
disableSubmodules
By disabling support for submodules you can still keep using basic git plugin functionality and just have Jenkins to ignore submodules completely as if they didn't exist.
Type:boolean
recursiveSubmodules
Retrieve all submodules recursively (uses '--recursive' option which requires git>=1.6.5)
Type:boolean
trackingSubmodules
Retrieve the tip of the configured branch in .gitmodules (Uses '--remote' option which requires git>=1.8.2)
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
To prepare a reference folder with multiple subprojects, create a bare git repository and add all the remote urls then perform a fetch:
  git init --bare
  git remote add SubProject1 https://gitrepo.com/subproject1
  git remote add SubProject2 https://gitrepo.com/subproject2
  git fetch --all
  
Type:String
timeout
Specify a timeout (in minutes) for submodules operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
parentCredentials
Use credentials from the default remote of the parent project.
Type:boolean
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
shallow (optional)
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
threads (optional)
Specify the number of threads that will be used to update submodules.
If unspecified, the command line git default thread count is used.
Type:int
$class: 'UserIdentityTrait'
extension
Nested object
name

If given, "GIT_COMMITTER_NAME=[this]" and "GIT_AUTHOR_NAME=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
email

If given, "GIT_COMMITTER_EMAIL=[this]" and "GIT_AUTHOR_EMAIL=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
bitbucketWebhookConfiguration

Sets the value for committersToIgnore in the Bitbucket Webhook. Value should be a comma separated string.

committerToIgnore is used to prevent triggering Jenkins builds when commits by certain users are made.

committersToIgnore
Type:String
bitbucketWebhookRegistration

Overrides the defaults for webhook management.

Webhooks are used to inform Jenkins about changes to repositories. There are two ways webhooks can be configured:

  • Manual webhook configuration requires the user to configure Bitbucket with the Jenkins URL in order to ensure that Bitbucket will send the events to Jenkins after every change.
  • Automatic webhook configuration requires that Jenkins has credentials with sufficient permission to configure webhooks and also that Jenkins knows the URL that Bitbucket can connect to.

The Manage Jenkins » Configure Jenkins › Bitbucket Endpoints allows defining the list of servers. Each server can be associated with credentials. If credentials are defined then the default behaviour is to use those credentials to automatically manage the webhooks of all repositories that Jenkins is interested in. If no credentials are defined then the default behaviour is to require the user to manually configure webhooks.

mode
There are two available modes:
Disable hook management
Disables hook management irrespective of the global defaults.
Use item credentials for hook management
Enabled hook management but uses the selected credentials to manage the hooks rather than those defined in Manage Jenkins » Configure Jenkins › Bitbucket Endpoints
Type:String
headWildcardFilter
includes
Space-separated list of name patterns to consider. You may use * as a wildcard; for example: master release*
NOTE: this filter will be applied to all branch like things, including change requests
Type:String
excludes
Space-separated list of name patterns to ignore even if matched by the includes list. For example: release alpha-* beta-*
NOTE: this filter will be applied to all branch like things, including change requests
Type:String
$class: 'WipeWorkspaceTrait'
bitbucketBranchDiscovery
Discovers branches on the repository.
strategyId
Determines which branches are discovered.
Exclude branches that are also filed as PRs
If you are discovering origin pull requests, it may not make sense to discover the same changes both as a pull request and as a branch.
Only branches that are also filed as PRs
Discovers branches that have PR's associated with them. This may make sense if you have a notification sent to the team at the end of a triggered build or limited Jenkins resources.
All branches
Ignores whether the branch is also filed as a pull request and instead discovers all branches on the origin repository.
Type:int
bitbucketForkDiscovery
Discovers pull requests where the origin repository is a fork of the target repository.
strategyId
Determines how pull requests are discovered.
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging
Type:int
trust

One of the great powers of pull requests is that anyone with read access to a repository can fork it, commit some changes to their fork and then create a pull request against the original repository with their changes. There are some files stored in source control that are important. For example, a Jenkinsfile may contain configuration details to sandbox pull requests in order to mitigate against malicious pull requests. In order to protect against a malicious pull request itself modifying the Jenkinsfile to remove the protections, you can define the trust policy for pull requests from forks.

Other plugins can extend the available trust policies. The default policies are:

Nobody
Pull requests from forks will all be treated as untrusted. This means that where Jenkins requires a trusted file (e.g. Jenkinsfile) the contents of that file will be retrieved from the target branch on the origin repository and not from the pull request branch on the fork repository.
Forks in the same account
Bitbucket allows for a repository to be forked into a "sibling" repository in the same account but using a different name. This strategy will trust any pull requests from forks that are in the same account as the target repository on the basis that users have to have been granted write permission to account in order create such a fork.
Everyone
All pull requests from forks will be treated as trusted. NOTE: this option can be dangerous if used on a public repository hosted on Bitbucket Cloud.
java.lang.UnsupportedOperationException: do not know how to categorize attributes of type jenkins.scm.api.trait.SCMHeadAuthority<? super com.cloudbees.jenkins.plugins.bitbucket.BitbucketSCMSourceRequest, ? extends jenkins.scm.api.mixin.ChangeRequestSCMHead2, ? extends jenkins.scm.api.SCMRevision>
bitbucketPullRequestDiscovery
Discovers pull requests where the origin repository is the same as the target repository.
strategyId
Determines how pull requests are discovered.
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging
Type:int
bitbucketSshCheckout
By default the discovered branches / pull requests will all use the same credentials that were used for discovery when checking out sources. This means that the checkout will be using the https:// protocol for the Git repository.

This behaviour allows you to select the SSH private key to be used for checking out sources, which will consequently force the checkout to use the ssh:// protocol.

credentialsId
Credentials used to check out sources.

It must be a SSH key based credential.

Type:String
bitbucketTagDiscovery
Discovers tags on the repository.
$class: 'com.cloudogu.scmmanager.scm.BranchDiscoveryTrait'
$class: 'com.cloudogu.scmmanager.scm.TagDiscoveryTrait'
gitBranchDiscovery
Discovers branches on the repository.
gitTagDiscovery
Discovers tags on the repository.
gitHubBranchDiscovery
Discovers branches on the repository.
strategyId
Determines which branches are discovered.
Exclude branches that are also filed as PRs
If you are discovering origin pull requests, you may not want to also build the source branches for those pull requests.
Only branches that are also filed as PRs
Similar to discovering origin pull requests, but discovers the branch rather than the pull request. This means env.GIT_BRANCH will be set to the branch name rather than PR-#. Also, status notifications for these builds will only be applied to the commit and not to the pull request.
All branches
Ignores whether the branch is also filed as a pull request and instead discovers all branches on the origin repository.
Type:int
gitHubForkDiscovery
Discovers pull requests where the origin repository is a fork of the target repository.
strategyId
Determines how pull requests are discovered:
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch.
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging.
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging.
Type:int
trust

One of the great powers of pull requests is that anyone with read access to a repository can fork it, commit some changes to their fork and then create a pull request against the original repository with their changes. There are some files stored in source control that are important. For example, a Jenkinsfile may contain configuration details to sandbox pull requests in order to mitigate against malicious pull requests. In order to protect against a malicious pull request itself modifying the Jenkinsfile to remove the protections, you can define the trust policy for pull requests from forks.

Other plugins can extend the available trust policies. The default policies are:

Nobody
Pull requests from forks will all be treated as untrusted. This means that where Jenkins requires a trusted file (e.g. Jenkinsfile) the contents of that file will be retrieved from the target branch on the origin repository and not from the pull request branch on the fork repository.
Collaborators
Pull requests from collaborators to the origin repository will be treated as trusted, all other pull requests from fork repositories will be treated as untrusted. Note that if credentials used by Jenkins for scanning the repository does not have permission to query the list of collaborators to the origin repository then only the origin account will be treated as trusted - i.e. this will fall back to Nobody. NOTE: all collaborators are trusted, even if they are only members of a team with read permission.
Everyone
All pull requests from forks will be treated as trusted. NOTE: this option can be dangerous if used on a public repository hosted on GitHub.
From users with Admin or Write permission
Pull requests forks will be treated as trusted if and only if the fork owner has either Admin or Write permissions on the origin repository. This is the recommended policy. Note that this strategy requires the Review a user's permission level API, as a result on GitHub Enterprise Server versions before 2.12 this is the same as trusting Nobody.
java.lang.UnsupportedOperationException: do not know how to categorize attributes of type jenkins.scm.api.trait.SCMHeadAuthority<? super org.jenkinsci.plugins.github_branch_source.GitHubSCMSourceRequest, ? extends jenkins.scm.api.mixin.ChangeRequestSCMHead2, ? extends jenkins.scm.api.SCMRevision>
gitHubPullRequestDiscovery
Discovers pull requests where the origin repository is the same as the target repository.
strategyId
Determines how pull requests are discovered:
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch.
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging.
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging.
Type:int
gitHubSshCheckout
By default the discovered branches / pull requests will all use the same username / password credentials that were used for discovery when checking out sources. This means that the checkout will be using the https:// protocol for the Git repository.

This behaviour allows you to select the SSH private key to be used for checking out sources, which will consequently force the checkout to use the ssh:// protocol.

credentialsId
Credentials used to check out sources. Must be a SSH key based credential.
Type:String
gitHubTagDiscovery
Discovers tags on the repository.
scmManager
serverUrl
Specify the root URL of the SCM-Manager instance including the context path (such as https://scm-manager.org/scm/) or an ssh URL (such as ssh://scm-manager.com:2222/; this requires the SSH plugin in SCM-Manager).
Type:String
repository
Select an existing repository from the SCM-Manager instance.
Type:String
credentialsId
Select valid credentials for the specified SCM-Manager instance.
Type:String
id (optional)
Type:String
traits (optional)
Array/List:
Nested choice of objects
$class: 'AuthorInChangelogTrait'
bitbucketBuildStatusNotifications
Configure the Bitbucket notifications.
disableNotificationForNotBuildJobs (optional)
Type:boolean
sendSuccessNotificationForUnstableBuild (optional)
Type:boolean
$class: 'CheckoutOptionTrait'
extension
Nested object
timeout
Specify a timeout (in minutes) for checkout.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
$class: 'CleanAfterCheckoutTrait'
extension
Nested object
Clean up the workspace after every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CleanBeforeCheckoutTrait'
extension
Nested object
Clean up the workspace before every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CleanMercurialSCMSourceTrait'
When this behaviour is present, each build will wipe any local modifications or untracked files in the repository checkout. This is often a convenient way to ensure that a build is not using any artifacts from earlier builds.
$class: 'CloneOptionTrait'
extension
Nested object
shallow
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
noTags
Deselect this to perform a clone without tags, saving time and disk space when you just want to access what is specified by the refspec.
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
Type:String
timeout
Specify a timeout (in minutes) for clone and fetch operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
honorRefspec (optional)
Perform initial clone using the refspec defined for the repository. This can save time, data transfer and disk space when you only need to access the references specified by the refspec.
Type:boolean
$class: 'DiscoverOtherRefsTrait'
Discovers other specified refs on the repository.
ref

The pattern under /refs on the remote repository to discover, can contain a wildcard.
Example: test/*/merged

Type:String
nameMapping (optional)

Mapping for how the ref can be named in for example the @Library.
Example: test-@{1}
Where @{1} replaces the first wildcard in the ref when discovered.

By default it will be "namespace_before_wildcard-@{1}". E.g. if ref is "test/*/merged" the default mapping would be "test-@{1}".

Type:String
$class: 'GitBrowserSCMSourceTrait'
browser
Nested choice of objects
$class: 'AssemblaWeb'
repoUrl
Specify the root URL serving this repository (such as https://www.assembla.com/code/PROJECT/git/).
Type:String
bitbucketServer
repoUrl
Specify the Bitbucket Server root URL for this repository (such as https://bitbucket:7990/OWNER/REPO/).
Type:String
$class: 'BitbucketWeb'
repoUrl
Specify the root URL serving this repository (such as https://bitbucket.org/OWNER/REPO/).
Type:String
$class: 'CGit'
repoUrl
Specify the root URL serving this repository (such as http://cgit.example.com:port/group/REPO/).
Type:String
$class: 'FisheyeGitRepositoryBrowser'
repoUrl
Specify the URL of this repository in FishEye (such as http://fisheye6.cenqua.com/browse/ant/).
Type:String
$class: 'GitBlitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository.
Type:String
projectName
Specify the name of the project in GitBlit.
Type:String
$class: 'GitLab'
repoUrl
Specify the root URL serving this repository (such as http://gitlabserver:port/group/REPO/).
Type:String
version (optional)
Specify the major and minor version of GitLab you use (such as 9.1). If you don't specify a version, a modern version of GitLab (>= 8.0) is assumed.
Type:String
$class: 'GitList'
repoUrl
Specify the root URL serving this repository (such as http://gitlistserver:port/REPO/).
Type:String
$class: 'GitWeb'
repoUrl
Specify the root URL serving this repository (such as https://github.com/jenkinsci/jenkins.git).
Type:String
$class: 'GithubWeb'
repoUrl
Specify the HTTP URL for this repository's GitHub page (such as https://github.com/jquery/jquery).
Type:String
$class: 'Gitiles'
repoUrl
Specify the root URL serving this repository (such as https://gwt.googlesource.com/gwt/).
Type:String
$class: 'GitoriousWeb'
repoUrl
Specify the root URL serving this repository (such as https://gitorious.org/gitorious/mainline).
Type:String
$class: 'GogsGit'
repoUrl
Specify the root URL serving this repository (such as http://gogs.example.com:port/username/some-repo-url.git).
Type:String
$class: 'KilnGit'
repoUrl
Specify the root URL serving this repository (such as https://khanacademy.kilnhg.com/Code/Website/Group/webapp).
Type:String
$class: 'Phabricator'
repoUrl
Specify the phabricator instance root URL (such as http://phabricator.example.com).
Type:String
repo
Specify the repository name in phabricator (such as the foo part of phabricator.example.com/diffusion/foo/browse).
Type:String
$class: 'RedmineWeb'
repoUrl
Specify the root URL serving this repository (such as http://SERVER/PATH/projects/PROJECT/repository).
Type:String
$class: 'RhodeCode'
repoUrl
Specify the HTTP URL for this repository's RhodeCode page (such as http://rhodecode.mydomain.com:5000/projects/PROJECT/repos/REPO/).
Type:String
$class: 'ScmManagerGitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository (such as https://scm-manager.org/scm/repo/namespace/name).
Type:String
$class: 'Stash'
repoUrl
Specify the HTTP URL for this repository's Stash page (such as http://stash.mydomain.com:7990/projects/PROJECT/repos/REPO/).
Type:String
$class: 'TFS2013GitRepositoryBrowser'
repoUrl
Either the name of the remote whose URL should be used, or the URL of this module in TFS (such as http://fisheye6.cenqua.com/tfs/PROJECT/_git/REPO/). If empty (default), the URL of the "origin" repository is used.

If TFS is also used as the repository server, this can usually be left blank.

Type:String
$class: 'ViewGitWeb'
repoUrl
Specify the root URL serving this repository (such as http://code.fealdia.org/viewgit/).
Type:String
projectName
Specify the name of the project in ViewGit (e.g. scripts, scuttle etc. from http://code.fealdia.org/viewgit/).
Type:String
$class: 'GitLFSPullTrait'
$class: 'GitToolSCMSourceTrait'
gitTool
Type:String
gitHubIgnoreDraftPullRequestFilter
$class: 'IgnoreOnPushNotificationTrait'
$class: 'LocalBranchTrait'
$class: 'MercurialBrowserSCMSourceTrait'
browser
Nested choice of objects
$class: 'FishEye'
url
Specify the root URL serving this repository, such as: http://www.example.org/browse/hg/
Type:String
$class: 'GoogleCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'HgWeb'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'Kallithea'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'KilnHG'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCodeLegacy'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'ScmManager'
url
Specify the root URL serving this repository (such as http://YOURSCMMANAGER/scm/repo/NAMESPACE/NAME/).
Type:String
$class: 'MercurialInstallationSCMSourceTrait'
installation
Type:String
$class: 'PruneStaleBranchTrait'
$class: 'PruneStaleTagTrait'
bitbucketPublicRepoPullRequestFilter
If the repository being scanned is a public repository, this behaviour will exclude all pull requests. (Note: This behaviour is not especially useful if scanning a single repository as you could just not include the pull request discovery behaviours in the first place)
$class: 'PullRequestDiscoveryTrait'
excludeBranchesWithPRs
Exclude branches for which there is an open pull request
Type:boolean
$class: 'RefSpecsSCMSourceTrait'
templates
Array/List:
Nested object
value
A ref spec to fetch. Any occurrences of @{remote} will be replaced by the remote name (which defaults to origin) before use.
Type:String
headRegexFilter
regex
A Java regular expression to restrict the names. Names that do not match the supplied regular expression will be ignored.
NOTE: this filter will be applied to all branch like things, including change requests
Type:String
$class: 'RemoteNameSCMSourceTrait'
remoteName
Type:String
$class: 'SparseCheckoutPathsTrait'
extension
Nested object

Specify the paths that you'd like to sparse checkout. This may be used for saving space (Think about a reference repository). Be sure to use a recent version of Git, at least above 1.7.10

sparseCheckoutPaths
Array/List:
Nested object
path
Type:String
$class: 'SubmoduleOptionTrait'
extension
Nested object
disableSubmodules
By disabling support for submodules you can still keep using basic git plugin functionality and just have Jenkins to ignore submodules completely as if they didn't exist.
Type:boolean
recursiveSubmodules
Retrieve all submodules recursively (uses '--recursive' option which requires git>=1.6.5)
Type:boolean
trackingSubmodules
Retrieve the tip of the configured branch in .gitmodules (Uses '--remote' option which requires git>=1.8.2)
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
To prepare a reference folder with multiple subprojects, create a bare git repository and add all the remote urls then perform a fetch:
  git init --bare
  git remote add SubProject1 https://gitrepo.com/subproject1
  git remote add SubProject2 https://gitrepo.com/subproject2
  git fetch --all
  
Type:String
timeout
Specify a timeout (in minutes) for submodules operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
parentCredentials
Use credentials from the default remote of the parent project.
Type:boolean
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
shallow (optional)
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
threads (optional)
Specify the number of threads that will be used to update submodules.
If unspecified, the command line git default thread count is used.
Type:int
$class: 'UserIdentityTrait'
extension
Nested object
name

If given, "GIT_COMMITTER_NAME=[this]" and "GIT_AUTHOR_NAME=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
email

If given, "GIT_COMMITTER_EMAIL=[this]" and "GIT_AUTHOR_EMAIL=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
bitbucketWebhookConfiguration

Sets the value for committersToIgnore in the Bitbucket Webhook. Value should be a comma separated string.

committerToIgnore is used to prevent triggering Jenkins builds when commits by certain users are made.

committersToIgnore
Type:String
bitbucketWebhookRegistration

Overrides the defaults for webhook management.

Webhooks are used to inform Jenkins about changes to repositories. There are two ways webhooks can be configured:

  • Manual webhook configuration requires the user to configure Bitbucket with the Jenkins URL in order to ensure that Bitbucket will send the events to Jenkins after every change.
  • Automatic webhook configuration requires that Jenkins has credentials with sufficient permission to configure webhooks and also that Jenkins knows the URL that Bitbucket can connect to.

The Manage Jenkins » Configure Jenkins › Bitbucket Endpoints allows defining the list of servers. Each server can be associated with credentials. If credentials are defined then the default behaviour is to use those credentials to automatically manage the webhooks of all repositories that Jenkins is interested in. If no credentials are defined then the default behaviour is to require the user to manually configure webhooks.

mode
There are two available modes:
Disable hook management
Disables hook management irrespective of the global defaults.
Use item credentials for hook management
Enabled hook management but uses the selected credentials to manage the hooks rather than those defined in Manage Jenkins » Configure Jenkins › Bitbucket Endpoints
Type:String
headWildcardFilter
includes
Space-separated list of name patterns to consider. You may use * as a wildcard; for example: master release*
NOTE: this filter will be applied to all branch like things, including change requests
Type:String
excludes
Space-separated list of name patterns to ignore even if matched by the includes list. For example: release alpha-* beta-*
NOTE: this filter will be applied to all branch like things, including change requests
Type:String
$class: 'WipeWorkspaceTrait'
bitbucketBranchDiscovery
Discovers branches on the repository.
strategyId
Determines which branches are discovered.
Exclude branches that are also filed as PRs
If you are discovering origin pull requests, it may not make sense to discover the same changes both as a pull request and as a branch.
Only branches that are also filed as PRs
Discovers branches that have PR's associated with them. This may make sense if you have a notification sent to the team at the end of a triggered build or limited Jenkins resources.
All branches
Ignores whether the branch is also filed as a pull request and instead discovers all branches on the origin repository.
Type:int
bitbucketForkDiscovery
Discovers pull requests where the origin repository is a fork of the target repository.
strategyId
Determines how pull requests are discovered.
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging
Type:int
trust

One of the great powers of pull requests is that anyone with read access to a repository can fork it, commit some changes to their fork and then create a pull request against the original repository with their changes. There are some files stored in source control that are important. For example, a Jenkinsfile may contain configuration details to sandbox pull requests in order to mitigate against malicious pull requests. In order to protect against a malicious pull request itself modifying the Jenkinsfile to remove the protections, you can define the trust policy for pull requests from forks.

Other plugins can extend the available trust policies. The default policies are:

Nobody
Pull requests from forks will all be treated as untrusted. This means that where Jenkins requires a trusted file (e.g. Jenkinsfile) the contents of that file will be retrieved from the target branch on the origin repository and not from the pull request branch on the fork repository.
Forks in the same account
Bitbucket allows for a repository to be forked into a "sibling" repository in the same account but using a different name. This strategy will trust any pull requests from forks that are in the same account as the target repository on the basis that users have to have been granted write permission to account in order create such a fork.
Everyone
All pull requests from forks will be treated as trusted. NOTE: this option can be dangerous if used on a public repository hosted on Bitbucket Cloud.
java.lang.UnsupportedOperationException: do not know how to categorize attributes of type jenkins.scm.api.trait.SCMHeadAuthority<? super com.cloudbees.jenkins.plugins.bitbucket.BitbucketSCMSourceRequest, ? extends jenkins.scm.api.mixin.ChangeRequestSCMHead2, ? extends jenkins.scm.api.SCMRevision>
bitbucketPullRequestDiscovery
Discovers pull requests where the origin repository is the same as the target repository.
strategyId
Determines how pull requests are discovered.
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging
Type:int
bitbucketSshCheckout
By default the discovered branches / pull requests will all use the same credentials that were used for discovery when checking out sources. This means that the checkout will be using the https:// protocol for the Git repository.

This behaviour allows you to select the SSH private key to be used for checking out sources, which will consequently force the checkout to use the ssh:// protocol.

credentialsId
Credentials used to check out sources.

It must be a SSH key based credential.

Type:String
bitbucketTagDiscovery
Discovers tags on the repository.
$class: 'com.cloudogu.scmmanager.scm.BranchDiscoveryTrait'
$class: 'com.cloudogu.scmmanager.scm.TagDiscoveryTrait'
gitBranchDiscovery
Discovers branches on the repository.
gitTagDiscovery
Discovers tags on the repository.
gitHubBranchDiscovery
Discovers branches on the repository.
strategyId
Determines which branches are discovered.
Exclude branches that are also filed as PRs
If you are discovering origin pull requests, you may not want to also build the source branches for those pull requests.
Only branches that are also filed as PRs
Similar to discovering origin pull requests, but discovers the branch rather than the pull request. This means env.GIT_BRANCH will be set to the branch name rather than PR-#. Also, status notifications for these builds will only be applied to the commit and not to the pull request.
All branches
Ignores whether the branch is also filed as a pull request and instead discovers all branches on the origin repository.
Type:int
gitHubForkDiscovery
Discovers pull requests where the origin repository is a fork of the target repository.
strategyId
Determines how pull requests are discovered:
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch.
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging.
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging.
Type:int
trust

One of the great powers of pull requests is that anyone with read access to a repository can fork it, commit some changes to their fork and then create a pull request against the original repository with their changes. There are some files stored in source control that are important. For example, a Jenkinsfile may contain configuration details to sandbox pull requests in order to mitigate against malicious pull requests. In order to protect against a malicious pull request itself modifying the Jenkinsfile to remove the protections, you can define the trust policy for pull requests from forks.

Other plugins can extend the available trust policies. The default policies are:

Nobody
Pull requests from forks will all be treated as untrusted. This means that where Jenkins requires a trusted file (e.g. Jenkinsfile) the contents of that file will be retrieved from the target branch on the origin repository and not from the pull request branch on the fork repository.
Collaborators
Pull requests from collaborators to the origin repository will be treated as trusted, all other pull requests from fork repositories will be treated as untrusted. Note that if credentials used by Jenkins for scanning the repository does not have permission to query the list of collaborators to the origin repository then only the origin account will be treated as trusted - i.e. this will fall back to Nobody. NOTE: all collaborators are trusted, even if they are only members of a team with read permission.
Everyone
All pull requests from forks will be treated as trusted. NOTE: this option can be dangerous if used on a public repository hosted on GitHub.
From users with Admin or Write permission
Pull requests forks will be treated as trusted if and only if the fork owner has either Admin or Write permissions on the origin repository. This is the recommended policy. Note that this strategy requires the Review a user's permission level API, as a result on GitHub Enterprise Server versions before 2.12 this is the same as trusting Nobody.
java.lang.UnsupportedOperationException: do not know how to categorize attributes of type jenkins.scm.api.trait.SCMHeadAuthority<? super org.jenkinsci.plugins.github_branch_source.GitHubSCMSourceRequest, ? extends jenkins.scm.api.mixin.ChangeRequestSCMHead2, ? extends jenkins.scm.api.SCMRevision>
gitHubPullRequestDiscovery
Discovers pull requests where the origin repository is the same as the target repository.
strategyId
Determines how pull requests are discovered:
Merging the pull request with the current target branch revision
Discover each pull request once with the discovered revision corresponding to the result of merging with the current revision of the target branch.
The current pull request revision
Discover each pull request once with the discovered revision corresponding to the pull request head revision without merging.
Both the current pull request revision and the pull request merged with the current target branch revision
Discover each pull request twice. The first discovered revision corresponds to the result of merging with the current revision of the target branch in each scan. The second parallel discovered revision corresponds to the pull request head revision without merging.
Type:int
gitHubSshCheckout
By default the discovered branches / pull requests will all use the same username / password credentials that were used for discovery when checking out sources. This means that the checkout will be using the https:// protocol for the Git repository.

This behaviour allows you to select the SSH private key to be used for checking out sources, which will consequently force the checkout to use the ssh:// protocol.

credentialsId
Credentials used to check out sources. Must be a SSH key based credential.
Type:String
gitHubTagDiscovery
Discovers tags on the repository.
scmManagerSvn
serverUrl
Specify the root URL of the SCM-Manager instance including the context path (such as https://scm-manager.org/scm/).
Type:String
repository
Select an existing repository from the SCM-Manager instance.
Type:String
id (optional)
Type:String
credentialsId (optional)
Select valid credentials for the specified SCM-Manager instance.
Type:String
browser (optional)
Nested choice of objects
$class: 'Assembla'
spaceName
Type:String
$class: 'CollabNetSVN'
url
The repository browser URL for the root of the project. For example, a Java.net project called myproject would use https://myproject.dev.java.net/source/browse/myproject.
Type:String
$class: 'FishEyeSVN'
url
Specify the URL of this module in FishEye. (such as http://fisheye6.cenqua.com/browse/ant/)
Type:String
rootModule
Specify the root Subversion module that this FishEye monitors. For example, for http://fisheye6.cenqua.com/browse/ant/, this field would be ant because it displays the directory "/ant" of the ASF repo. If FishEye is configured to display the whole SVN repository, leave this field empty.
Type:String
svnPhabricator
url
Type:String
repo
Type:String
$class: 'SVNWeb'
url
Type:String
$class: 'ScmManagerSvnRepositoryBrowser'
repoUrl
Specify the root URL serving this repository (such as https://scm-manager.org/scm/repo/namespace/name).
Type:String
$class: 'Sventon'
url
Specify the URL of the Sventon repository browser. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be http://somehost.com/svn/
Type:String
repositoryInstance
Specify the Sventon repository instance name that references this subversion repository. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be local
Type:String
$class: 'Sventon2'
url
Specify the URL of the Sventon repository browser. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be http://somehost.com/svn/
Type:String
repositoryInstance
Specify the Sventon repository instance name that references this subversion repository. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be local
Type:String
$class: 'ViewSVN'
url
Specify the root URL of ViewSVN for this repository (such as this).
Type:String
$class: 'VisualSVN'
url
Specify the root URL of VisualSVN for this repository (such as https://demo-server.visualsvn.com/!/#tortoisesvn).
Type:String
$class: 'WebSVN'
url
Type:String
excludes (optional)
Optionally specify branches to be excluded from builds using glob expressions.
Type:String
includes (optional)
Specify the branches to be build using glob expressions (like trunk,branches/*,tags/*,sandbox/*).
Type:String
workspaceUpdater (optional)
Nested choice of objects
$class: 'CheckoutUpdater'
$class: 'NoopUpdater'
$class: 'UpdateUpdater'
$class: 'UpdateWithCleanUpdater'
$class: 'UpdateWithRevertUpdater'
fromScm
name
The name of the SCM head/trunk/branch/tag that this source provides.
Type:String
scm
Nested choice of objects
$class: 'GitSCM'

The git plugin provides fundamental git operations for Jenkins projects. It can poll, fetch, checkout, and merge contents of git repositories.

The git plugin provides an SCM implementation to be used with the Pipeline SCM checkout step. The Pipeline Syntax Snippet Generator guides the user to select git plugin checkout options and provides online help for each of the options.

userRemoteConfigs
Specify the repository to track. This can be a URL or a local file path. Note that for super-projects (repositories with submodules), only a local file path or a complete URL is valid. The following are examples of valid git URLs.
  • ssh://git@github.com/github/git.git
  • git@github.com:github/git.git (short notation for ssh protocol)
  • ssh://user@other.host.com/~/repos/R.git (to access the repos/R.git repository in the user's home directory)
  • https://github.com/github/git.git

If the repository is a super-project, the location from which to clone submodules is dependent on whether the repository is bare or non-bare (i.e. has a working directory).
  • If the super-project is bare, the location of the submodules will be taken from .gitmodules.
  • If the super-project is not bare, it is assumed that the repository has each of its submodules cloned and checked out appropriately. Thus, the submodules will be taken directly from a path like ${SUPER_PROJECT_URL}/${SUBMODULE}, rather than relying on information from .gitmodules.
For a local URL/path to a super-project, git rev-parse --is-bare-repository is used to detect whether the super-project is bare or not.
For a remote URL to a super-project, the ending of the URL determines whether a bare or non-bare repository is assumed:
  • If the remote URL ends with /.git, a non-bare repository is assumed.
  • If the remote URL does NOT end with /.git, a bare repository is assumed.
Array/List:
Nested object
url
Specify the URL or path of the git repository. This uses the same syntax as your git clone command.
Type:String
name
ID of the repository, such as origin, to uniquely identify this repository among other remote repositories. This is the same "name" that you use in your git remote command. If left empty, Jenkins will generate unique names for you.

You normally want to specify this when you have multiple remote repositories.

Type:String
refspec
A refspec controls the remote refs to be retrieved and how they map to local refs. If left blank, it will default to the normal behaviour of git fetch, which retrieves all the branch heads as remotes/REPOSITORYNAME/BRANCHNAME. This default behaviour is OK for most cases.

In other words, the default refspec is "+refs/heads/*:refs/remotes/REPOSITORYNAME/*" where REPOSITORYNAME is the value you specify in the above "name of repository" textbox.

When do you want to modify this value? A good example is when you want to just retrieve one branch. For example, +refs/heads/master:refs/remotes/origin/master would only retrieve the master branch and nothing else.

The plugin uses a default refspec for its initial fetch, unless the "Advanced Clone Option" is set to honor refspec. This keeps compatibility with previous behavior, and allows the job definition to decide if the refspec should be honored on initial clone.

Multiple refspecs can be entered by separating them with a space character. +refs/heads/master:refs/remotes/origin/master +refs/heads/develop:refs/remotes/origin/develop retrieves the master branch and the develop branch and nothing else.

See the refspec definition in Git user manual for more details.

Type:String
credentialsId
Credential used to check out sources.
Type:String
branches
List of branches to build. Jenkins jobs are most effective when each job builds only a single branch. When a single job builds multiple branches, the changelog comparisons between branches often show no changes or incorrect changes.
Array/List:
Nested object
name

Specify the branches if you'd like to track a specific branch in a repository. If left blank, all branches will be examined for changes and built.

The safest way is to use the refs/heads/<branchName> syntax. This way the expected branch is unambiguous.

If your branch name has a / in it make sure to use the full reference above. When not presented with a full path the plugin will only use the part of the string right of the last slash. Meaning foo/bar will actually match bar.

If you use a wildcard branch specifier, with a slash (e.g. release/), you'll need to specify the origin repository in the branch names to make sure changes are picked up. So e.g. origin/release/

Possible options:

  • <branchName>
    Tracks/checks out the specified branch. If ambiguous the first result is taken, which is not necessarily the expected one. Better use refs/heads/<branchName>.
    E.g. master, feature1, ...
  • refs/heads/<branchName>
    Tracks/checks out the specified branch.
    E.g. refs/heads/master, refs/heads/feature1/master, ...
  • <remoteRepoName>/<branchName>
    Tracks/checks out the specified branch. If ambiguous the first result is taken, which is not necessarily the expected one.
    Better use refs/heads/<branchName>.
    E.g. origin/master
  • remotes/<remoteRepoName>/<branchName>
    Tracks/checks out the specified branch.
    E.g. remotes/origin/master
  • refs/remotes/<remoteRepoName>/<branchName>
    Tracks/checks out the specified branch.
    E.g. refs/remotes/origin/master
  • <tagName>
    This does not work since the tag will not be recognized as tag.
    Use refs/tags/<tagName> instead.
    E.g. git-2.3.0
  • refs/tags/<tagName>
    Tracks/checks out the specified tag.
    E.g. refs/tags/git-2.3.0
  • <commitId>
    Checks out the specified commit.
    E.g. 5062ac843f2b947733e6a3b105977056821bd352, 5062ac84, ...
  • ${ENV_VARIABLE}
    It is also possible to use environment variables. In this case the variables are evaluated and the result is used as described above.
    E.g. ${TREEISH}, refs/tags/${TAGNAME}, ...
  • <Wildcards>
    The syntax is of the form: REPOSITORYNAME/BRANCH. In addition, BRANCH is recognized as a shorthand of */BRANCH, '*' is recognized as a wildcard, and '**' is recognized as wildcard that includes the separator '/'. Therefore, origin/branches* would match origin/branches-foo but not origin/branches/foo, while origin/branches** would match both origin/branches-foo and origin/branches/foo.
  • :<regular expression>
    The syntax is of the form: :regexp. Regular expression syntax in branches to build will only build those branches whose names match the regular expression.
    Examples:
    • :^(?!(origin/prefix)).*
      • matches: origin or origin/master or origin/feature
      • does not match: origin/prefix or origin/prefix_123 or origin/prefix-abc
    • :origin/release-\d{8}
      • matches: origin/release-20150101
      • does not match: origin/release-2015010 or origin/release-201501011 or origin/release-20150101-something
    • :^(?!origin/master$|origin/develop$).*
      • matches: origin/branch1 or origin/branch-2 or origin/master123 or origin/develop-123
      • does not match: origin/master or origin/develop

Type:String
browser
Defines the repository browser that displays changes detected by the git plugin.
Nested choice of objects
$class: 'AssemblaWeb'
repoUrl
Specify the root URL serving this repository (such as https://www.assembla.com/code/PROJECT/git/).
Type:String
bitbucketServer
repoUrl
Specify the Bitbucket Server root URL for this repository (such as https://bitbucket:7990/OWNER/REPO/).
Type:String
$class: 'BitbucketWeb'
repoUrl
Specify the root URL serving this repository (such as https://bitbucket.org/OWNER/REPO/).
Type:String
$class: 'CGit'
repoUrl
Specify the root URL serving this repository (such as http://cgit.example.com:port/group/REPO/).
Type:String
$class: 'FisheyeGitRepositoryBrowser'
repoUrl
Specify the URL of this repository in FishEye (such as http://fisheye6.cenqua.com/browse/ant/).
Type:String
$class: 'GitBlitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository.
Type:String
projectName
Specify the name of the project in GitBlit.
Type:String
$class: 'GitLab'
repoUrl
Specify the root URL serving this repository (such as http://gitlabserver:port/group/REPO/).
Type:String
version (optional)
Specify the major and minor version of GitLab you use (such as 9.1). If you don't specify a version, a modern version of GitLab (>= 8.0) is assumed.
Type:String
$class: 'GitList'
repoUrl
Specify the root URL serving this repository (such as http://gitlistserver:port/REPO/).
Type:String
$class: 'GitWeb'
repoUrl
Specify the root URL serving this repository (such as https://github.com/jenkinsci/jenkins.git).
Type:String
$class: 'GithubWeb'
repoUrl
Specify the HTTP URL for this repository's GitHub page (such as https://github.com/jquery/jquery).
Type:String
$class: 'Gitiles'
repoUrl
Specify the root URL serving this repository (such as https://gwt.googlesource.com/gwt/).
Type:String
$class: 'GitoriousWeb'
repoUrl
Specify the root URL serving this repository (such as https://gitorious.org/gitorious/mainline).
Type:String
$class: 'GogsGit'
repoUrl
Specify the root URL serving this repository (such as http://gogs.example.com:port/username/some-repo-url.git).
Type:String
$class: 'KilnGit'
repoUrl
Specify the root URL serving this repository (such as https://khanacademy.kilnhg.com/Code/Website/Group/webapp).
Type:String
$class: 'Phabricator'
repoUrl
Specify the phabricator instance root URL (such as http://phabricator.example.com).
Type:String
repo
Specify the repository name in phabricator (such as the foo part of phabricator.example.com/diffusion/foo/browse).
Type:String
$class: 'RedmineWeb'
repoUrl
Specify the root URL serving this repository (such as http://SERVER/PATH/projects/PROJECT/repository).
Type:String
$class: 'RhodeCode'
repoUrl
Specify the HTTP URL for this repository's RhodeCode page (such as http://rhodecode.mydomain.com:5000/projects/PROJECT/repos/REPO/).
Type:String
$class: 'ScmManagerGitRepositoryBrowser'
repoUrl
Specify the root URL serving this repository (such as https://scm-manager.org/scm/repo/namespace/name).
Type:String
$class: 'Stash'
repoUrl
Specify the HTTP URL for this repository's Stash page (such as http://stash.mydomain.com:7990/projects/PROJECT/repos/REPO/).
Type:String
$class: 'TFS2013GitRepositoryBrowser'
repoUrl
Either the name of the remote whose URL should be used, or the URL of this module in TFS (such as http://fisheye6.cenqua.com/tfs/PROJECT/_git/REPO/). If empty (default), the URL of the "origin" repository is used.

If TFS is also used as the repository server, this can usually be left blank.

Type:String
$class: 'ViewGitWeb'
repoUrl
Specify the root URL serving this repository (such as http://code.fealdia.org/viewgit/).
Type:String
projectName
Specify the name of the project in ViewGit (e.g. scripts, scuttle etc. from http://code.fealdia.org/viewgit/).
Type:String
gitTool

Absolute path to the git executable.

This is different from other Jenkins tool definitions. Rather than providing the directory that contains the executable, you must provide the complete path to the executable. Setting '/usr/bin/git' would be correct, while setting '/usr/bin/' is not correct.

Type:String
extensions

Extensions add new behavior or modify existing plugin behavior for different uses. Extensions help users more precisely tune plugin behavior to meet their needs.

Extensions include:

  • Clone extensions modify the git operations that retrieve remote changes into the agent workspace. The extensions can adjust the amount of history retrieved, how long the retrieval is allowed to run, and other retrieval details.
  • Checkout extensions modify the git operations that place files in the workspace from the git repository on the agent. The extensions can adjust the maximum duration of the checkout operation, the use and behavior of git submodules, the location of the workspace on the disc, and more.
  • Changelog extensions adapt the source code difference calculations for different cases.
  • Tagging extensions allow the plugin to apply tags in the current workspace.
  • Build initiation extensions control the conditions that start a build. They can ignore notifications of a change or force a deeper evaluation of the commits when polling.
  • Merge extensions can optionally merge changes from other branches into the current branch of the agent workspace. They control the source branch for the merge and the options applied to the merge.

Array/List:
Nested choice of objects
$class: 'AuthorInChangelog'
The default behavior is to use the Git commit's "Committer" value in Jenkins' build changesets. If this option is selected, the Git commit's "Author" value would be used instead.
$class: 'BuildChooserSetting'
When you are interested in using a job to build multiple heads (most typically multiple branches), you can choose how Jenkins choose what branches to build in what order.

This extension point in Jenkins is used by many other plugins to control the job to build specific commits. When you activate those plugins, you may see them installing a custom strategy here.

buildChooser
Nested choice of objects
$class: 'AncestryBuildChooser'
maximumAgeInDays
Type:int
ancestorCommitSha1
Type:String
$class: 'DefaultBuildChooser'
$class: 'InverseBuildChooser'
$class: 'BuildSingleRevisionOnly'
Disable scheduling for multiple candidate revisions.
If we have 3 branches:
----A--.---.--- B
         \-----C
jenkins would try to build (B) and (C).
This behaviour disables this and only builds one of them.
It is helpful to reduce the load of the Jenkins infrastructure when the SCM system like Bitbucket or GitHub should decide what commits to build.
$class: 'ChangelogToBranch'
This method calculates the changelog against the specified branch.
options
Nested object
compareRemote
Name of the repository, such as origin, that contains the branch you specify below.
Type:String
compareTarget
The name of the branch within the named repository to compare against.
Type:String
$class: 'CheckoutOption'
timeout
Specify a timeout (in minutes) for checkout.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
$class: 'CleanBeforeCheckout'
Clean up the workspace before every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CleanCheckout'
Clean up the workspace after every checkout by deleting all untracked files and directories, including those which are specified in .gitignore. It also resets all tracked files to their versioned state. This ensures that the workspace is in the same state as if you cloned and checked out in a brand-new empty directory, and ensures that your build is not affected by the files generated by the previous build.
deleteUntrackedNestedRepositories (optional)
Deletes untracked submodules and any other subdirectories which contain .git directories.
Type:boolean
$class: 'CloneOption'
shallow
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
noTags
Deselect this to perform a clone without tags, saving time and disk space when you just want to access what is specified by the refspec.
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
Type:String
timeout
Specify a timeout (in minutes) for clone and fetch operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
honorRefspec (optional)
Perform initial clone using the refspec defined for the repository. This can save time, data transfer and disk space when you only need to access the references specified by the refspec.
Type:boolean
$class: 'DisableRemotePoll'
Git plugin uses git ls-remote polling mechanism by default when configured with a single branch (no wildcards!). This compare the latest built commit SHA with the remote branch without cloning a local copy of the repo.

If you don't want to / can't use this.

If this option is selected, polling will require a workspace and might trigger unwanted builds (see JENKINS-10131).
$class: 'GitLFSPull'
Enable git large file support for the workspace by pulling large files after the checkout completes. Requires that the controller and each agent performing an LFS checkout have installed `git lfs`.
$class: 'IgnoreNotifyCommit'
If checked, this repository will be ignored when the notifyCommit-URL is accessed regardless of if the repository matches or not.
$class: 'LocalBranch'
If given, checkout the revision to build as HEAD on this branch.

If selected, and its value is an empty string or "**", then the branch name is computed from the remote branch without the origin. In that case, a remote branch origin/master will be checked out to a local branch named master, and a remote branch origin/develop/new-feature will be checked out to a local branch named develop/newfeature.

Please note that this has not been tested with submodules.

localBranch
Type:String
$class: 'MessageExclusion'
excludedMessage
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions committed with message matched to Pattern when determining if a build needs to be triggered. This can be used to exclude commits done by the build itself from triggering another build, assuming the build server commits the change with a distinct message.

Exclusion uses Pattern matching

.*\[maven-release-plugin\].*
The example above illustrates that if only revisions with "[maven-release-plugin]" message in first comment line have been committed to the SCM a build will not occur.

You can create more complex patterns using embedded flag expressions.

(?s).*FOO.*
This example will search FOO message in all comment lines.
Type:String
$class: 'PathRestriction'
If set, and Jenkins is set to poll for changes, Jenkins will pay attention to included and/or excluded files and/or folders when determining if a build needs to be triggered.

Using this behaviour will preclude the faster git ls-remote polling mechanism, forcing polling to require a workspace thus sometimes triggering unwanted builds, as if you had selected the Force polling using workspace extension as well.

includedRegions
Each inclusion uses java regular expression pattern matching, and must be separated by a new line. An empty list implies that everything is included.

    myapp/src/main/web/.*\.html
    myapp/src/main/web/.*\.jpeg
    myapp/src/main/web/.*\.gif
  
The example above illustrates that a build will only occur, if html/jpeg/gif files have been committed to the SCM. Exclusions take precedence over inclusions, if there is an overlap between included and excluded regions.
Type:String
excludedRegions
Each exclusion uses java regular expression pattern matching, and must be separated by a new line.

    myapp/src/main/web/.*\.html
    myapp/src/main/web/.*\.jpeg
    myapp/src/main/web/.*\.gif
  
The example above illustrates that if only html/jpeg/gif files have been committed to the SCM a build will not occur.
Type:String
$class: 'PerBuildTag'
Create a tag in the workspace for every build to unambiguously mark the commit that was built. You can combine this with Git publisher to push the tags to the remote repository.
$class: 'PreBuildMerge'
These options allow you to perform a merge to a particular branch before building. For example, you could specify an integration branch to be built, and to merge to master. In this scenario, on every change of integration, Jenkins will perform a merge with the master branch, and try to perform a build if the merge is successful. It then may push the merge back to the remote repository if the Git Push post-build action is selected.
options
Nested object
mergeTarget
The name of the branch within the named repository to merge to, such as master.
Type:String
fastForwardMode (optional)
Merge fast-forward mode selection.
The default, --ff, gracefully falls back to a merge commit when required.
For more information, see the Git Merge Documentation
Values:
FF
FF_ONLY
NO_FF
mergeRemote (optional)
Name of the repository, such as origin, that contains the branch you specify below. If left blank, it'll default to the name of the first repository configured above.
Type:String
mergeStrategy (optional)
Merge strategy selection. This feature is not fully implemented in JGIT.
Values:
DEFAULT
RESOLVE
RECURSIVE
OCTOPUS
OURS
SUBTREE
RECURSIVE_THEIRS
$class: 'PruneStaleBranch'
Run "git remote prune" for each remote, to prune obsolete local branches.
pruneTags
pruneTags
Type:boolean
$class: 'RelativeTargetDirectory'
relativeTargetDir
Specify a local directory (relative to the workspace root) where the Git repository will be checked out. If left empty, the workspace root itself will be used.

This extension should not be used in Jenkins Pipeline (either declarative or scripted). Jenkins Pipeline already provides standard techniques for checkout to a subdirectory. Use ws and dir in Jenkins Pipeline rather than this extension.

Type:String
$class: 'ScmName'

Unique name for this SCM. Needed when using Git within the Multi SCM plugin.

name
Type:String
$class: 'SparseCheckoutPaths'

Specify the paths that you'd like to sparse checkout. This may be used for saving space (Think about a reference repository). Be sure to use a recent version of Git, at least above 1.7.10

sparseCheckoutPaths
Array/List:
Nested object
path
Type:String
$class: 'SubmoduleOption'
disableSubmodules
By disabling support for submodules you can still keep using basic git plugin functionality and just have Jenkins to ignore submodules completely as if they didn't exist.
Type:boolean
recursiveSubmodules
Retrieve all submodules recursively (uses '--recursive' option which requires git>=1.6.5)
Type:boolean
trackingSubmodules
Retrieve the tip of the configured branch in .gitmodules (Uses '--remote' option which requires git>=1.8.2)
Type:boolean
reference
Specify a folder containing a repository that will be used by Git as a reference during clone operations.
This option will be ignored if the folder is not available on the controller or agent where the clone is being executed.
To prepare a reference folder with multiple subprojects, create a bare git repository and add all the remote urls then perform a fetch:
  git init --bare
  git remote add SubProject1 https://gitrepo.com/subproject1
  git remote add SubProject2 https://gitrepo.com/subproject2
  git fetch --all
  
Type:String
timeout
Specify a timeout (in minutes) for submodules operations.
This option overrides the default timeout of 10 minutes.
You can change the global git timeout via the property org.jenkinsci.plugins.gitclient.Git.timeOut (see JENKINS-11286). Note that property should be set on both controller and agent to have effect (see JENKINS-22547).
Type:int
parentCredentials
Use credentials from the default remote of the parent project.
Type:boolean
depth (optional)
Set shallow clone depth, so that git will only download recent history of the project, saving time and disk space when you just want to access the latest commits of a repository.
Type:int
shallow (optional)
Perform shallow clone, so that git will not download the history of the project, saving time and disk space when you just want to access the latest version of a repository.
Type:boolean
threads (optional)
Specify the number of threads that will be used to update submodules.
If unspecified, the command line git default thread count is used.
Type:int
$class: 'UserExclusion'
excludedUsers
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions committed by users in this list when determining if a build needs to be triggered. This can be used to exclude commits done by the build itself from triggering another build, assuming the build server commits the change with a distinct SCM user.

Using this behaviour will preclude the faster git ls-remote polling mechanism, forcing polling to require a workspace thus sometimes triggering unwanted builds, as if you had selected the Force polling using workspace extension as well.

Each exclusion uses exact string comparison and must be separated by a new line. User names are only excluded if they exactly match one of the names in this list.

auto_build_user
The example above illustrates that if only revisions by "auto_build_user" have been committed to the SCM a build will not occur.
Type:String
$class: 'UserIdentity'
name

If given, "GIT_COMMITTER_NAME=[this]" and "GIT_AUTHOR_NAME=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
email

If given, "GIT_COMMITTER_EMAIL=[this]" and "GIT_AUTHOR_EMAIL=[this]" are set for builds. This overrides whatever is in the global settings.

Type:String
$class: 'WipeWorkspace'
Delete the contents of the workspace before building, ensuring a fully fresh workspace.
doGenerateSubmoduleConfigurations (optional)

Removed facility that was intended to test combinations of git submodule versions. Removed in git plugin 4.6.0. Ignores the user provided value and always uses false as its value.

Type:boolean
submoduleCfg (optional)

Removed facility that was intended to test combinations of git submodule versions. Removed in git plugin 4.6.0. Ignores the user provided value(s) and always uses empty values.

Array/List:
Nested object
submoduleName

Removed in git plugin 4.6.0.

Type:String
branches

Removed in git plugin 4.6.0.

Array/List:
Type:String
$class: 'MercurialSCM'
source
Specify the repository to track. This can be URL or a local file path. If you are specifying HTTP credentials, do not include a username in the URL.
Type:String
browser (optional)
Nested choice of objects
$class: 'FishEye'
url
Specify the root URL serving this repository, such as: http://www.example.org/browse/hg/
Type:String
$class: 'GoogleCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'HgWeb'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'Kallithea'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'KilnHG'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCode'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'RhodeCodeLegacy'
url
Specify the root URL serving this repository (such as this).
Type:String
$class: 'ScmManager'
url
Specify the root URL serving this repository (such as http://YOURSCMMANAGER/scm/repo/NAMESPACE/NAME/).
Type:String
clean (optional)
When this option is checked, each build will wipe any local modifications or untracked files in the repository checkout. This is often a convenient way to ensure that a build is not using any artifacts from earlier builds.
Type:boolean
credentialsId (optional)
Optional credentials to use when cloning or pulling from the remote repository. Supports username/password with HTTP(S) URLs, and SSH private key with SSH URLs.
Type:String
disableChangeLog (optional)
When checked, Hudson will not calculate the Mercurial changelog for each build. Disabling the changelog can decrease the amount of time needed to update a very large repository.
Type:boolean
installation (optional)
Type:String
modules (optional)
Reduce unnecessary builds by specifying a comma or space delimited list of "modules" within the repository. A module is a directory name within the repository that this project lives in. If this field is set, changes outside the specified modules will not trigger a build (even though the whole repository is checked out anyway due to the Mercurial limitation.)
Type:String
revision (optional)
Specify the branch or tag name you would like to track. (If you do not type anything, the default value is the default branch.)
Type:String
revisionType (optional)
Specify the kind of revision you expect Jenkins to update your working copy to.
Values:
BRANCH
TAG
CHANGESET
REVSET
subdir (optional)
If not empty, check out the Mercurial repository into this subdirectory of the job's workspace. For example: my/sources (use forward slashes). If changing this entry, you probably want to clean the workspace first.
Type:String
none
$class: 'SubversionSCM'
Checks out the source code from Subversion repositories. See post-commit hook set up for improved turn-around time and performance in polling.
locations
Array/List:
Nested object
remote
Type:String
credentialsId
Type:String
local
Specify a local directory (relative to the workspace root) where this module is checked out. If left empty, the last path component of the URL is used as the default, just like the svn CLI. A single period (.) may be used to check out the project directly into the workspace rather than into a subdirectory.
Type:String
depthOption
--depth option for checkout and update commands. Default value is infinity.
  • empty includes only the immediate target of the operation, not any of its file or directory children.
  • files includes the immediate target of the operation and any of its immediate file children.
  • immediates includes the immediate target of the operation and any of its immediate file or directory children. The directory children will themselves be empty.
  • infinity includes the immediate target, its file and directory children, its children's children, and so on to full recursion.
  • as-it-is takes the working depth from the current working copy, allows for setting update depth manually using --set-depth option.
More information can be found here.
Type:String
ignoreExternalsOption
"--ignore-externals" option will be used with svn checkout, svn update commands to disable externals definition processing.

More information can be found here.
Note: there is the potential to leverage svn:externals to gain read access to the entire Subversion repository. This can happen if you follow the normal practice of giving Jenkins credentials with read access to the entire Subversion repository. You will also need to provide the credentials to use when checking/polling out the svn:externals using the Additional Credentials option.

Type:boolean
cancelProcessOnExternalsFail
Determines if the process should be cancelled when checkout/update svn:externals failed. Will work when "Ignore externals" box is not checked. Default choice is to cancelled the process when checkout/update svn:externals failed.
Type:boolean
workspaceUpdater
Nested choice of objects
$class: 'CheckoutUpdater'
$class: 'NoopUpdater'
$class: 'UpdateUpdater'
$class: 'UpdateWithCleanUpdater'
$class: 'UpdateWithRevertUpdater'
browser
Nested choice of objects
$class: 'Assembla'
spaceName
Type:String
$class: 'CollabNetSVN'
url
The repository browser URL for the root of the project. For example, a Java.net project called myproject would use https://myproject.dev.java.net/source/browse/myproject.
Type:String
$class: 'FishEyeSVN'
url
Specify the URL of this module in FishEye. (such as http://fisheye6.cenqua.com/browse/ant/)
Type:String
rootModule
Specify the root Subversion module that this FishEye monitors. For example, for http://fisheye6.cenqua.com/browse/ant/, this field would be ant because it displays the directory "/ant" of the ASF repo. If FishEye is configured to display the whole SVN repository, leave this field empty.
Type:String
svnPhabricator
url
Type:String
repo
Type:String
$class: 'SVNWeb'
url
Type:String
$class: 'ScmManagerSvnRepositoryBrowser'
repoUrl
Specify the root URL serving this repository (such as https://scm-manager.org/scm/repo/namespace/name).
Type:String
$class: 'Sventon'
url
Specify the URL of the Sventon repository browser. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be http://somehost.com/svn/
Type:String
repositoryInstance
Specify the Sventon repository instance name that references this subversion repository. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be local
Type:String
$class: 'Sventon2'
url
Specify the URL of the Sventon repository browser. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be http://somehost.com/svn/
Type:String
repositoryInstance
Specify the Sventon repository instance name that references this subversion repository. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be local
Type:String
$class: 'ViewSVN'
url
Specify the root URL of ViewSVN for this repository (such as this).
Type:String
$class: 'VisualSVN'
url
Specify the root URL of VisualSVN for this repository (such as https://demo-server.visualsvn.com/!/#tortoisesvn).
Type:String
$class: 'WebSVN'
url
Type:String
excludedRegions
If set, and Jenkins is set to poll for changes, Jenkins will ignore any files and/or folders in this list when determining if a build needs to be triggered.

Each exclusion uses regular expression pattern matching, and must be separated by a new line.

	/trunk/myapp/src/main/web/.*\.html
	/trunk/myapp/src/main/web/.*\.jpeg
	/trunk/myapp/src/main/web/.*\.gif
  
The example above illustrates that if only html/jpeg/gif files have been committed to the SCM a build will not occur.

More information on regular expressions can be found here.

Type:String
excludedUsers
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions committed by users in this list when determining if a build needs to be triggered. This can be used to exclude commits done by the build itself from triggering another build, assuming the build server commits the change with a distinct SCM user.

Each exclusion uses literal pattern matching, and must be separated by a new line.

	 auto_build_user
  
The example above illustrates that if only revisions by "auto_build_user" have been committed to the SCM a build will not occur.
Type:String
excludedRevprop
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions that are marked with the given revision property (revprop) when determining if a build needs to be triggered. This can be used to exclude commits done by the build itself from triggering another build, assuming the build server commits the change with the correct revprop.

This type of exclusion only works with Subversion 1.5 servers and newer.

More information on revision properties can be found here.

Type:String
excludedCommitMessages
If set, and Jenkins is set to poll for changes, Jenkins will ignore any revisions with commit messages containing any of the given regular expressions when determining if a build needs to be triggered.
Type:String
includedRegions
If set, and Jenkins is set to poll for changes, Jenkins will ignore any files and/or folders that are not in this list when determining if a build needs to be triggered.

Each inclusion uses regular expression pattern matching, and must be separated by a new line.

This is useful when you need to check out an entire resource for building, but only want to do the build when a subset has changed.

	/trunk/myapp/c/library1/.*
	/trunk/myapp/c/library2/.*
  
If /trunk/myapp is checked out, the build will only occur when there are changes to either the c/library1 and c/library2 subtrees.

If there are also excluded regions specified, then a file is not ignored when it is in the included list and not in the excluded list.

More information on regular expressions can be found here.

Type:String
ignoreDirPropChanges
If set, Jenkins ignores svn-property only changes of directories. These changes are ignored when determining whether a build should be triggered and are removed from a build's changeset. Main usage of this property is to ignore svn:mergeinfo changes (which would otherwise e.g. lead to a complete rebuild of a maven project, in spite of incremental build option).
Type:boolean
filterChangelog
If set Jenkins will apply the same inclusion and exclusion patterns for displaying changelog entries as it does for polling for changes. If this is disabled, changes which are excluded for polling are still displayed in the changelog.
Type:boolean
additionalCredentials

If there are additional credentials required in order to obtain a complete checkout of the source, they can be provided here.

The realm is how the repository self-identifies to a client. It usually has the following format:

<proto://host:port> Realm Name

  • proto is the protocol, e.g. http or svn.
  • host is the host how it's accessed by Jenkins, e.g. as IP address 192.168.1.100, host name svnserver, or host name and domain svn.example.org.
  • port is the port, even if not explicitly specified. By default, this is 80 for HTTP, 443 for HTTPS, 3690 for the svn protocol.
  • Realm Name is how the repository self-identifies. Common options include VisualSVN Server, Subversion Authentication or the UUID of the repository.

To find out the realm, you could do any of the following:

  • If you access the repository via HTTP or HTTPS: Open the repo in a web browser without saved credentials. It will use the Realm Name (see above) in the authentication dialog.
  • Use the command line svn program.
    • If you don't have stored the credentials, run e.g. svn info https://svnserver/repo and it will tell you the realm when asking you to enter a password, e.g.: Authentication realm: <svn://svnserver:3690> VisualSVN Server.
    • If you have already stored the credentials to access the repository, look for the realm name in one of the files in ~/.subversion/auth/svn/simple; it will be two lines below the line svn:realmstring.
  • When accessing a repository via the svn+ssh protocol, the realm has the format username@svn+ssh://host:port – note that the username is before the svn+ssh:// (unlike the URL used for normal SVN operations), and that there are no angle brackets and no realm name. For this protocol the default port is 22.

Make sure to enter the realm exactly as shown, starting with a < (except for repositories accessed via svn+ssh – see above).

Array/List:
Nested object
realm
This is the realm that the SvnKit library associates with a specific checkout. For most Subversion servers this will typically be of the format <scheme://hostname(:port)> name, while for servers accessed via svn+ssh it is of the format (username@)svn+ssh://hostname(:port).
Type:String
credentialsId
Select the credential from the list of relevant credentials in order to use that credential for checking out the source code.
Type:String
quietOperation

Mimics subversion command line --quiet parameter for check out / update operations to help keep the output shorter. Prints nothing, or only summary information.

Type:boolean
id (optional)
Type:String
$class: 'SubversionSCMSource'
remoteBase
Type:String
id (optional)
Type:String
browser (optional)
Nested choice of objects
$class: 'Assembla'
spaceName
Type:String
$class: 'CollabNetSVN'
url
The repository browser URL for the root of the project. For example, a Java.net project called myproject would use https://myproject.dev.java.net/source/browse/myproject.
Type:String
$class: 'FishEyeSVN'
url
Specify the URL of this module in FishEye. (such as http://fisheye6.cenqua.com/browse/ant/)
Type:String
rootModule
Specify the root Subversion module that this FishEye monitors. For example, for http://fisheye6.cenqua.com/browse/ant/, this field would be ant because it displays the directory "/ant" of the ASF repo. If FishEye is configured to display the whole SVN repository, leave this field empty.
Type:String
svnPhabricator
url
Type:String
repo
Type:String
$class: 'SVNWeb'
url
Type:String
$class: 'ScmManagerSvnRepositoryBrowser'
repoUrl
Specify the root URL serving this repository (such as https://scm-manager.org/scm/repo/namespace/name).
Type:String
$class: 'Sventon'
url
Specify the URL of the Sventon repository browser. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be http://somehost.com/svn/
Type:String
repositoryInstance
Specify the Sventon repository instance name that references this subversion repository. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be local
Type:String
$class: 'Sventon2'
url
Specify the URL of the Sventon repository browser. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be http://somehost.com/svn/
Type:String
repositoryInstance
Specify the Sventon repository instance name that references this subversion repository. For example, if you normally browse from http://somehost.com/svn/repobrowser.svn?name=local, this field would be local
Type:String
$class: 'ViewSVN'
url
Specify the root URL of ViewSVN for this repository (such as this).
Type:String
$class: 'VisualSVN'
url
Specify the root URL of VisualSVN for this repository (such as https://demo-server.visualsvn.com/!/#tortoisesvn).
Type:String
$class: 'WebSVN'
url
Type:String
credentialsId (optional)
Type:String
excludes (optional)
Type:String
includes (optional)
Type:String
workspaceUpdater (optional)
Nested choice of objects
$class: 'CheckoutUpdater'
$class: 'NoopUpdater'
$class: 'UpdateUpdater'
$class: 'UpdateWithCleanUpdater'
$class: 'UpdateWithRevertUpdater'
libraryPath (optional)
A relative path from the root of the SCM to the root of the library. Leave this field blank if the root of the library is the root of the SCM. Note that ".." is not permitted as a path component to avoid security issues.
Type:String
libraryResource: Load a resource file from a library
Reads a resource from a library and returns its content as a plain string.
resource
Relative (/-separated) path to a resource in a library's /resources folder.
Type:String
encoding (optional)
The encoding to use when reading the resource. If left blank, the platform default encoding will be used. Binary files can be read into a Base64-encoded string by specifying "Base64" as the encoding.
Type:String
load: Evaluate a Groovy source file into the Pipeline script
Takes a filename in the workspace and runs it as Groovy source text.

The loaded file can contain statements at top level or just load and run a closure. For example:

    def pipeline
    node('slave') {
        pipeline = load 'pipeline.groovy'
        pipeline.functionA()
    }
    pipeline.functionB()
    

Where pipeline.groovy defines functionA and functionB functions (among others) before ending with return this;

path

Current directory (pwd()) relative path to the Groovy file to load.

Type:String
lock: Lock shared resource
resource

The resource name to lock as defined in Global settings. If the resource does not exist in Global Settings it will be automatically created on build execution. Either a resource or a label need to be specified.

Type:String
extra (optional)
Array/List:
Nested object
resource

The resource name to lock as defined in Global settings. If the resource does not exist in Global Settings it will be automatically created on build execution. Either a resource or a label need to be specified.

Type:String
label (optional)

The label of the resources to be locked as defined in Global settings. Either a resource or a label need to be specified.

Type:String
quantity (optional)

The quantity of resources with the specified label to be locked as defined in Global settings. Either a resource or a label need to be specified. Empty value or 0 means lock all matching resources.

Type:int
inversePrecedence (optional)

By default waiting builds get the lock in the same order they requested to acquire it.

By checking this option the newest build in the waiting queue will get the lock first.

Type:boolean
label (optional)

The label of the resources to be locked as defined in Global settings. Either a resource or a label need to be specified.

Type:String
quantity (optional)

The quantity of resources with the specified label to be locked as defined in Global settings. Either a resource or a label need to be specified. Empty value or 0 means lock all matching resources.

Type:int
skipIfLocked (optional)

By default waiting builds get the lock.

By checking this option the body will not be executed if there is a queue. It will only take the lock if it can be taken immediately.

Type:boolean
variable (optional)

Name of an environment variable that will receive the comma separated list of the names of the locked resources while the block executes.

e.g.:

lock(label: 'label', variable: 'var') {
    echo "Resource locked: ${env.var}"
}
		

Type:String
mail: Mail
Simple step for sending email.
subject
Email subject line.
Type:String
body
Email body.
Type:String
bcc (optional)
BCC email address list. Comma separated list of email addresses.
Type:String
cc (optional)
CC email address list. Comma separated list of email addresses.
Type:String
charset (optional)
Email body character encoding. Defaults to UTF-8
Type:String
from (optional)
From email address. Defaults to the admin address globally configured for the Jenkins instance.
Type:String
mimeType (optional)
Email body MIME type. Defaults to text/plain.
Type:String
replyTo (optional)
Reploy-To email address. Defaults to the admin address globally configured for the Jenkins instance.
Type:String
to (optional)
To email address list. Comma separated list of email addresses.
Type:String
milestone: The milestone step forces all builds to go through in order

By default, Pipeline builds can run concurrently.

The milestone step forces all builds to go through in order, so an older build will never be allowed pass a milestone (it is aborted) if a newer build already passed it.

In general this step grants:

  • Builds pass milestones in order (taking the build number as sorter field).
  • Older builds will not proceed (they are aborted) if a newer one already passed the milestone.
  • When a build passes a milestone, any older build that passed the previous milestone but not this one is aborted.
  • Once a build passes the milestone, it will never be aborted by a newer build that didn't pass the milestone yet.

ordinal

An optional ordinal for the milestone. It is autogenerated if not explicitly set.

Setting explicit milestone ordinals grants that each milestone can be univocally identified across builds even when script changes are made during a previous build. If you plan to add or remove milestone steps while there are running builds and trigger new builds before the previous ones finished, then you should set explicit milestone ordinals. Otherwise, let the step autogenerate them as it runs.

Type:int
label (optional)

A label for the milestone. It's shown in the build log metadata.

Type:String
unsafe (optional)

An optional flag to allow unsafe execution of the milestone step. Do not set unless you understand the risks.

Currently this will allow the execution of a milestone step within a parallel step. It is assumed only 1 branch can contain a milestone step.

Type:boolean
mineRepository: Mine SCM repository
scm (optional)
Type:String
moveComponents: Move Components (Nexus Repository Manager 3.x)
nexusInstanceId
Type:String
destination
The repository to which components will be moved
Type:String
search (optional)
java.lang.UnsupportedOperationException: do not know how to categorize attributes of type java.util.Map<java.lang.String, java.lang.String>
tagName (optional)
Components associated with this tag will be moved to the selected destination repository
Type:String
nexusPolicyEvaluation: Invoke Nexus Policy Evaluation
iqStage
Controls the stage the policy evaluation will be run against on the Nexus IQ Server.
Type:String
iqInstanceId (optional)
Type:String
advancedProperties (optional)
Provide advanced properties to the IQ Server in <key>=<value> pairs, with each additional property appearing on a new line. eg:
key1=value1
key2=value2
Type:String
enableDebugLogging (optional)
Type:boolean
failBuildOnNetworkError (optional)
Controls the build outcome if there is a failure in communicating with the Nexus IQ Server (e.g. network outage). If checked, the build will be marked as failed. Otherwise, the build is only marked as unstable.
Type:boolean
iqApplication (optional)
Nested choice of objects
(not enumerable)
iqModuleExcludes (optional)
A comma-separated list of Ant-style patterns relative to the workspace root that denote the module information files (**/nexus-iq/module.xml) to be ignored, e.g. **/my-module/target/**, **/another-module/target/**. If unspecified all modules will contribute dependency information (if any) to the scan.
Array/List:
Nested object
moduleExclude
Type:String
iqScanPatterns (optional)
A list of Ant-style patterns relative to the workspace root that denote the files/archives to be scanned, e.g. **/target/*.war or **/target/*.ear. If unspecified, the scan will default to the patterns **/*.jar, **/*.war, **/*.ear, **/*.zip, **/*.tar.gz.
Array/List:
Nested object
scanPattern
Type:String
jobCredentialsId (optional)
To use the IQ server credentials configured in Nexus global configuration for this job select - none -, otherwise select different credentials.
Type:String
nexusPublisher: Nexus Repository Manager Publisher
nexusInstanceId
Type:String
nexusRepositoryId
The publisher currently supports hosted release Maven 2 repositories. This list is limited to repositories which meet this requirement.
Type:String
packages
Array/List:
Nested choice of objects
$class: 'MavenPackage'
mavenCoordinate
Nested object
groupId
Type:String
artifactId
Type:String
version
Type:String
packaging
Type:String
mavenAssetList
Array/List:
Nested object
filePath
Type:String
classifier
Type:String
extension
Type:String
tagName (optional)
Tag is only available for Nexus Repository Manager 3+
Type:String
node: Allocate node
Allocates an executor on a node (typically a build agent) and runs further code in the context of a workspace on that agent.
label
Computer name, label name, or any other label expression like linux && 64bit to restrict where this step builds. May be left blank, in which case any available executor is taken.

Supported operators

The following operators are supported, in descending order of precedence:
(expression)
parentheses — used to explicitly define the associativity of an expression
!expression
NOT — negation; the result of expression must not be true
a && b
AND — both of the expressions a and b must be true
a || b
OR — either of the expressions a or b may be true
a -> b
"implies" operator — equivalent to !a || b.
For example, windows -> x64 could be thought of as "if a Windows agent is used, then that agent must be 64-bit", while still allowing this block to be executed on any agents that do not have the windows label, regardless of whether they have also have an x64 label
a <-> b
"if and only if" operator — equivalent to a && b || !a && !b
For example, windows <-> dc2 could be thought of as "if a Windows agent is used, then that agent must be in datacenter 2, but if a non-Windows agent is used, then it must not be in datacenter 2"

Notes

  • All operators are left-associative, i.e. a -> b -> c is equivalent to (a -> b) -> c.
  • Labels or agent names can be surrounded with quotation marks if they contain characters that would conflict with the operator syntax.
    For example, "osx (10.11)" || "Windows Server".
  • Expressions can be written without whitespace, but including it is recommended for readability; Jenkins will ignore whitespace when evaluating expressions.
  • Matching labels or agent names with wildcards or regular expressions is not supported.
  • An empty expression will always evaluate to true, matching all agents.

Examples

master
This block may be executed only on the Jenkins built-in node
linux-machine-42
This block may be executed only on the agent with the name linux-machine-42 (or on any machine that happens to have a label called linux-machine-42)
windows && jdk9
This block may be executed only on any Windows agent that has version 9 of the Java Development Kit installed (assuming that agents with JDK 9 installed have been given a jdk9 label)
postgres && !vm && (linux || freebsd)
This block may be executed only any on Linux or FreeBSD agent, so long as they are not a virtual machine, and they have PostgreSQL installed (assuming that each agent has the appropriate labels — in particular, each agent running in a virtual machine must have the vm label in order for this example to work as expected)
Type:String
nodesByLabel: List of nodes by Label, by default excludes offline nodes.
Returns an array of node names with the given label.
label
Type:String
offline (optional)
Type:boolean
parallel: Execute in parallel
org.kohsuke.stapler.NoStaplerConstructorException: There's no @DataBoundConstructor on any constructor of class org.jenkinsci.plugins.workflow.cps.steps.ParallelStep
podTemplate: Define a podTemplate to use in the kubernetes plugin

Defines a Kubernetes pod template that can be used to create nodes.

Example:

podTemplate(...) {
    node(POD_LABEL) {
        // some steps
    }
}
activeDeadlineSeconds (optional)
Type:int
annotations (optional)
Array/List:
podAnnotation
key
The annotation key.
Type:String
value
The annotation value.
Type:String
cloud (optional)
The Kubernetes cloud to use to schedule the pod.
If unset, the first available Kubernetes cloud will be used.
Type:String
containers (optional)
Array/List:
containerTemplate
name
The name for the container to be run. One container is automatically created with name jnlp, and runs the Jenkins JNLP agent service. In order to replace the default JNLP agent, the name of the container with the custom JNLP image must be jnlp.
Type:String
image
Docker image ID for a jenkins JNLP agent. This image is responsible to run a jenkins jnlp bootstrap agent and connect to Jenkins controller. Secret key and agent name as well as jenkins callback URL are passed as argument as expected by hudson.remoting.jnlp.Main.
Type:String
alwaysPullImage (optional)
If ticked, the latest version of the image will be pulled every time it is used. See Images - Kubernetes for the default Kubernetes behaviour.
Type:boolean
args (optional)

Arguments to pass to the command.

${computer.jnlpmac} and ${computer.name} are replaced with the agent secret and name respectively.

For Windows containers the args Start-Sleep 999999 are reasonable choices to go with powershell.

Type:String
command (optional)

Override the image entrypoint with a different one.

For Windows containers powershell is a good default.

Type:String
envVars (optional)
The environment variables to pass to the container.
Array/List:
Nested choice of objects
containerEnvVar
key
The environment variable key.
Type:String
value
The environment variable value.
Type:String
envVar
key
The environment variable key.
Type:String
value
The environment variable value.
Type:String
podEnvVar
key
The environment variable key.
Type:String
value
The environment variable value.
Type:String
secretEnvVar
key
The environment variable key.
Type:String
secretName
Name of secret to lookup from Kubernetes.
Type:String
secretKey
Key of secret to lookup from Kubernetes.
Type:String
optional
Whether this secret is optional.
Type:boolean
livenessProbe (optional)
containerLivenessProbe
execArgs
Command executed by the liveness probe.
Type:String
timeoutSeconds
Number of seconds after which the probe times out. Defaults to 1 second. Minimum value is 1.
Type:int
initialDelaySeconds
Number of seconds after the container has started before liveness or readiness probes are initiated. Defaults to 0 seconds. Minimum value is 0.
Type:int
failureThreshold

When a Pod starts and the probe fails, Kubernetes will try failureThreshold times before giving up.
Giving up in case of liveness probe means restarting the container.
In case of readiness probe the Pod will be marked Unready. Defaults to 3. Minimum value is 1.

Type:int
periodSeconds

How often (in seconds) to perform the probe. Default to 10 seconds. Minimum value is 1.

Type:int
successThreshold
Minimum consecutive successes for the probe to be considered successful after having failed. Defaults to 1. Must be 1 for liveness. Minimum value is 1.
Type:int
ports (optional)
Array/List:
portMapping
name (optional)
The name of the port
Type:String
containerPort (optional)
Port to expose into the pod
Type:int
hostPort (optional)
Port to expose onto the host
Type:int
privileged (optional)
Flag to mark the container as privileged.
Type:boolean
resourceLimitCpu (optional)
Kubernetes Resources Limit of CPU This value can be set to control the CPU resource limit passed when creating the Jenkins agent Docker container in Kubernetes. Unlike a resource request, this is the upper limit of resources used by your Jenkins Agent container. When left blank, the defaults of your Kubernetes cluster will be used. For more info, see the Kubernetes docs. e.g. `500m`.
Type:String
resourceLimitEphemeralStorage (optional)
Type:String
resourceLimitMemory (optional)
Kubernetes Resources Limit of Memory This value can be set to control the memory resource limit passed when creating the Jenkins agent Docker container in Kubernetes. Unlike a resource request, this is the upper limit of resources used by your Jenkins Agent container. When left blank, the defaults of your Kubernetes cluster will be used. For more info, see the Kubernetes docs. e.g. `250Mi`.
Type:String
resourceRequestCpu (optional)
Kubernetes Resources Request of CPU This value can be set to control the CPU resources requested when creating the Jenkins agent Docker container in Kubernetes. When left blank, the defaults of your Kubernetes cluster will be used. For more info, see the Kubernetes docs. e.g. `500m`.
Type:String
resourceRequestEphemeralStorage (optional)
Type:String
resourceRequestMemory (optional)
Kubernetes Resources Request of Memory This value can be set to control the memory resources requested when creating the Jenkins agent Docker container in Kubernetes. When left blank, the defaults of your Kubernetes cluster will be used. For more info, see the Kubernetes docs. e.g. `250Mi`.
Type:String
runAsGroup (optional)
Specify the gid to run as.
Type:String
runAsUser (optional)
Specify the uid to run as.
Type:String
shell (optional)
Type:String
ttyEnabled (optional)
Whether this container should allocate a TTY for itself.
Type:boolean
workingDir (optional)
Path to the root of the workspace from the view point of this container, such as /home/jenkins/agent.
Type:String
envVars (optional)
Array/List:
Nested choice of objects
containerEnvVar
key
The environment variable key.
Type:String
value
The environment variable value.
Type:String
envVar
key
The environment variable key.
Type:String
value
The environment variable value.
Type:String
podEnvVar
key
The environment variable key.
Type:String
value
The environment variable value.
Type:String
secretEnvVar
key
The environment variable key.
Type:String
secretName
Name of secret to lookup from Kubernetes.
Type:String
secretKey
Key of secret to lookup from Kubernetes.
Type:String
optional
Whether this secret is optional.
Type:boolean
hostNetwork (optional)
Type:boolean
idleMinutes (optional)
Type:int
imagePullSecrets (optional)
Array/List:
Type:String
inheritFrom (optional)
Type:String
instanceCap (optional)
Type:int
label (optional)
Jenkins node label to bind. If left blank, one will be generated for you, and inside the step it will be bound to the variable POD_LABEL so you can use this as the argument to the node step.
Example:
        podTemplate(...) {
            node(POD_LABEL) {
                // some steps
            }
        }
    
Type:String
name (optional)
Type:String
namespace (optional)
Type:String
nodeSelector (optional)
Type:String
nodeUsageMode (optional)
Type:String
podRetention (optional)
Nested choice of objects
always
default
never
onFailure
runAsGroup (optional)
Type:String
runAsUser (optional)
Type:String
schedulerName (optional)
Type:String
serviceAccount (optional)
Type:String
showRawYaml (optional)
Type:boolean
slaveConnectTimeout (optional)
Type:int
supplementalGroups (optional)
Type:String
volumes (optional)
Array/List:
Nested choice of objects
configMapVolume
mountPath
Path to mount this volume inside the pod.
Type:String
configMapName
The name of the Kubernetes Config Map to mount into the pod.
Type:String
optional
Whether this configmap needs to exist.
Type:boolean
subPath (optional)
SubPath to mount this volume inside the pod.
Type:String
dynamicPVC
accessModes (optional)
A PersistentVolume can be mounted on a host in any way supported by the resource provider. Providers will have different capabilities and each PV’s access modes are set to the specific modes supported by that particular volume. For example, NFS can support multiple read/write clients, but a specific NFS PV might be exported on the server as read-only. Each PV gets its own set of access modes describing that specific PV’s capabilities. Defaults to ReadWriteOnce.
Type:String
mountPath (optional)
Path to mount this volume inside the pod.
Type:String
requestsSize (optional)
Claims, like pods, can request specific quantities of a resource. In this case, the request is for storage. The same resource model applies to both volumes and claims. Defaults to 10Gi.
Type:String
storageClassName (optional)
A StorageClass provides a way for administrators to describe the “classes” of storage they offer. Different classes might map to quality-of-service levels, or to backup policies, or to arbitrary policies determined by the cluster administrators. Kubernetes itself is unopinionated about what classes represent. This concept is sometimes called “profiles” in other storage systems.
Type:String
emptyDirVolume
mountPath
Path to mount this volume inside the pod.
Type:String
memory
Flag for in-memory volume.
Type:boolean
hostPathVolume
hostPath
File or directory on the host node's filesystem to mount into the pod.
Type:String
mountPath
Path to mount this volume inside the pod.
Type:String
nfsVolume
serverAddress
NFS Server Address.
Type:String
serverPath
NFS Server Path.
Type:String
readOnly
Type:boolean
mountPath
Path to mount this volume inside the pod.
Type:String
persistentVolumeClaim
mountPath
Path to mount this volume inside the pod.
Type:String
claimName
The claim name.
Type:String
readOnly
Flag for read-only volume.
Type:boolean
secretVolume
mountPath
Path to mount this volume inside the pod.
Type:String
secretName
The name of the Kubernetes Secret to mount into the pod.
Type:String
defaultMode
The file permissions for the secret volume. Does not support Octal notation.
Type:String
optional
Whether the secret needs to exist.
Type:boolean
workingDir (optional)
Type:String
workspaceVolume (optional)
Nested choice of objects
dynamicPVC
accessModes (optional)
A PersistentVolume can be mounted on a host in any way supported by the resource provider. Providers will have different capabilities and each PV’s access modes are set to the specific modes supported by that particular volume. For example, NFS can support multiple read/write clients, but a specific NFS PV might be exported on the server as read-only. Each PV gets its own set of access modes describing that specific PV’s capabilities. Defaults to ReadWriteOnce.
Type:String
requestsSize (optional)
Claims, like pods, can request specific quantities of a resource. In this case, the request is for storage. The same resource model applies to both volumes and claims. Defaults to 10Gi.
Type:String
storageClassName (optional)
A StorageClass provides a way for administrators to describe the “classes” of storage they offer. Different classes might map to quality-of-service levels, or to backup policies, or to arbitrary policies determined by the cluster administrators. Kubernetes itself is unopinionated about what classes represent. This concept is sometimes called “profiles” in other storage systems.
Type:String
emptyDirWorkspaceVolume
memory
Flag for in-memory volume.
Type:boolean
hostPathWorkspaceVolume
hostPath
File or directory on the host node's filesystem to mount into the pod.
Type:String
nfsWorkspaceVolume
serverAddress
NFS Server Address.
Type:String
serverPath
NFS Server Path.
Type:String
readOnly
Type:boolean
persistentVolumeClaimWorkspaceVolume
claimName
The claim name.
Type:String
readOnly
Flag for read-only volume.
Type:boolean
yaml (optional)
Type:String
yamlMergeStrategy (optional)
Nested choice of objects
merge
override
powershell: Windows PowerShell Script
script
Executes a Windows PowerShell script (version 3 or later). Multiple lines allowed.
Note: be aware of the differences between Windows PowerShell and PowerShell Core, check which one is available on your agents.
Type:String
encoding (optional)
Encoding of process output. In the case of returnStdout, applies to the return value of this step; otherwise, or always for standard error, controls how text is copied to the build log. If unspecified, uses the system default encoding of the node on which the step is run. If there is any expectation that process output might include non-ASCII characters, it is best to specify the encoding explicitly. For example, if you have specific knowledge that a given process is going to be producing UTF-8 yet will be running on a node with a different system encoding (typically Windows, since every Linux distribution has defaulted to UTF-8 for a long time), you can ensure correct output by specifying: encoding: 'UTF-8'
Type:String
label (optional)
Label to be displayed in the pipeline step view and blue ocean details for the step instead of the step type. So the view is more meaningful and domain specific instead of technical.
Type:String
returnStatus (optional)
Normally, a script which exits with a nonzero status code will cause the step to fail with an exception. If this option is checked, the return value of the step will instead be the status code. You may then compare it to zero, for example.
Type:boolean
returnStdout (optional)
If checked, standard output from the task is returned as the step value as a String, rather than being printed to the build log. (Standard error, if any, will still be printed to the log.) You will often want to call .trim() on the result to strip off a trailing newline.
Type:boolean
prependToFile: Create a file (if not already exist) in the workspace, and prepend given content to that file.

Creates a file if it does not already exist, and prepends given content to it.

file

The path to the file that will be prepended.

Type:String
content

The content to prepend.

Type:String
properties: Set job properties
Updates the properties of the job which runs this step. Mainly useful from multibranch Pipelines, so that Jenkinsfile itself can encode what would otherwise be static job configuration. Existing properties set through the Jenkins UI for non-multibranch Pipelines will be preserved.
properties
Array/List:
Nested choice of objects
authorizationMatrix
permissions
Array/List:
Type:String
inheritanceStrategy (optional)
Nested choice of objects
inheritingGlobal
inheriting
nonInheriting
buildDiscarder
This determines when, if ever, build records for this project should be discarded. Build records include the console output, archived artifacts, and any other metadata related to a particular build.

Keeping fewer builds means less disk space will be used in the Build Record Root Directory, which is specified on the Configure System screen.

Jenkins offers two options for determining when builds should be discarded:

  1. Build age: discard builds when they reach a certain age; for example, seven days old.
  2. Build count: discard the oldest build when a certain number of builds already exist.
These two options can be active at the same time, so you can keep builds for 14 days, but only up to a limit of 50 builds, for example. If either limit is exceeded, then any builds beyond that limit will be discarded.

You can also ensure that important builds are kept forever, regardless of the setting here — click the Keep this build forever button on the build page.
The last stable and last successful build are also excluded from these rules.


In the Advanced section, the same options can be specified, but specifically for build artifacts. If enabled, build artifacts will be discarded for any builds which exceed the defined limits. The builds themselves will still be kept; only the associated artifacts, if any, will be deleted.

For example, if a project builds some software and produces a large installer, which is archived, you may wish to always keep the console log and information about which source control commit was built, while for disk space reasons, you may want to keep only the last three installers that were built.
This can make sense for projects where you can easily recreate the same artifacts later by building the same source control commit again.


Note that Jenkins does not discard items immediately when this configuration is updated, or as soon as any of the configured values are exceeded; these rules are evaluated each time a build of this project completes.
strategy
Nested choice of objects
logRotator
daysToKeepStr
Type:String
numToKeepStr
Type:String
artifactDaysToKeepStr
Type:String
artifactNumToKeepStr
Type:String
disableConcurrentBuilds
abortPrevious (optional)
By default, disabling concurrent builds means that new builds will queue up and wait for a running build to complete. With this option, scheduling a new build immediately aborts any running build. This is handy for example if you have an expensive pull request testing procedure and do not wish to waste any time completing tests on an outdated commit.
Type:boolean
disableResume
durabilityHint

This setting allows users to change the default durability mode for running Pipelines. In most cases this is a trade-off between performance and the ability for running pipelines to resume after unplanned Jenkins outages.

What does this do?

  • Previously, running pipelines wrote data constantly, so that they could resume even if Jenkins fails. This setting gives the user the ability to adjust this write behavior.
  • Higher-performance/lower-durability modes write data to disk much less often for running pipelines.
  • Writing data less often can massively reduce build times for Pipelines with many steps or complex logic. For pipelines which spend most of their time waiting for a shell/batch script to run, the difference will be less visible.
  • Running pipelines with lower durability settings may lose data if they do not finish and Jenkins is not shut down gracefully:
    • A "graceful" shutdown where Jenkins goes through a full shutdown process, such as visiting http://[jenkins-server]/exit
    • A "dirty" shutdown, such as using kill -9 to terminate the Jenkins process, may prevent incomplete pipelines from persisting data
  • Pipelines that cannot persist data may not be able to resume or displayed in Blue Ocean/Stage View/etc.
  • Pipelines will generally write log data regardless of durability settings.
  • Some modes use an "atomic write" option - this helps ensure that pipeline build files aren't overwritten or left partially written if something fails.
  • Atomic writes may place more stress on filesystems, so especially with networked storage it may be faster not to use them.

Note: defaults also be set globally under Manage Jenkins > Configure System.

hint
Values:
PERFORMANCE_OPTIMIZED
SURVIVABLE_NONATOMIC
MAX_SURVIVABILITY
githubProjectProperty
projectUrlStr

Enter the URL for the GitHub hosted project (without the tree/master or tree/branch part).

For example: https://github.com/rails/rails for the Rails project.

Type:String
displayName (optional)

This value will be used as context name for commit status if status builder or status publisher is defined for this project. It should be small and clear.

If you leave it empty, job name will be used for builder and publisher.

Type:String
overrideIndexTriggers

Allows overriding default treatment of branch indexing triggers.

If branch indexing triggers are disabled at the multibranch or organization label, selecting this will enable them for this job only.

Otherwise, leaving the checkbox unselected will disable branch indexing triggers for this job only.

enableTriggers
Type:boolean
parameters
Parameters allow you to prompt users for one or more inputs that will be passed into a build. For example, you might have a project that runs tests on demand by allowing users to upload a zip file with binaries to be tested. This could be done by adding a File Parameter here.
Or you might have a project that releases some software, and you want users to enter release notes that will be uploaded along with the software. This could be done by adding a Multi-line String Parameter here.

Each parameter has a Name and some sort of Value, depending on the parameter type. These name-value pairs will be exported as environment variables when the build starts, allowing subsequent parts of the build configuration (such as build steps) to access those values, e.g. by using the ${PARAMETER_NAME} syntax (or %PARAMETER_NAME% on Windows).
This also implies that each parameter defined here should have a unique Name.

When a project is parameterized, the usual Build Now link will be replaced with a Build with Parameters link, where users will be prompted to specify values for each of the defined parameters. If they choose not to enter anything, the build will start with the default value for each parameter.

If a build is started automatically, for example if started by an SCM trigger, the default values for each parameter will be used.

When a parameterized build is in the queue, attempting to start another build of the same project will only succeed if the parameter values are different, or if the Execute concurrent builds if necessary option is enabled.

See the Parameterized Builds documentation for more information about this feature.

parameterDefinitions
Array/List:
Nested choice of objects
booleanParam
name
Type:String
defaultValue (optional)
Type:boolean
description (optional)
Type:String
choice
name
Type:String
description (optional)
Type:String
choices (optional)
Nested choice of objects
(not enumerable)
credentials
Defines a credentials parameter, which you can use during a build.

For security reasons, the credential is NOT directly exposed, the ID of the credential is exposed.

However, the selected credential is available through variable substitution in some other parts of the configuration. The string value will be the ID of the credential. A supporting plugin can thus use the ID to retrieve the selected credential and expose it to the build in an appropriate way.
name
Type:String
defaultValue
The default credentials to use.
Type:String
credentialType
Type:String
required
When this option is selected, the credentials selection drop down will not provide the empty selection as one of the options. This will not prevent a build without a value if there are no credentials available, for example if the job does not have access to any credentials of the correct type or there is no default value and the user starting the build either does not have any credentials of the correct type in their personal credentials store or they do not have permissions on the job to use credentials from their personal store.
Type:boolean
description (optional)
Type:String
file
name
Type:String
description (optional)
Type:String
$class: 'ListSubversionTagsParameterDefinition'
When used, this parameter will display a field at build-time so that the user is able to select a Subversion tag from which to create the working copy for this project.

Once the two fields Name and Repository URL are set, you must

  1. ensure the job uses Subversion and
  2. set the Repository URL field of Subversion by concatenating the two fields of this parameter.
For instance, if Name is set to SVN_TAG and Repository URL is set to https://svn.jenkins-ci.org/tags, then Subversion's Repository URL must be set to https://svn.jenkins-ci.org/tags/$SVN_TAG.

Notice that you can set the Repository URL field to a Subversion repository root rather than just pointing to a tags dir (ie, you can set it to https://svn.jenkins-ci.org rather than https://svn.jenkins-ci.org/tags). In that case, if this repository root contains the trunk, branches and tags folders, then the dropdown will allow the user to pick the trunk, or a branch, or a tag.

name
Type:String
tagsDir
Specify the Subversion repository URL which contains the tags to be listed when triggering a new build.

You can also specify the root of a Subversion repository: If this root contains the trunk, branches and tags folders, then the dropdown will display trunk, all the branches and all the tags. If the root does not contain these three folders, then all its subfolders are listed in the dropdown.

When you enter the URL, Jenkins automatically checks if it can connect to it. If access requires authentication, you'll be prompted for the necessary credential. If you already have a working credential but would like to change it for some other reasons, you can manage credentials and specify a different credential.

Type:String
credentialsId
Type:String
tagsFilter
Specify a regular expression which will be used to filter the tags which are actually displayed when triggering a new build.
Type:String
defaultValue
For features such as SVN polling a default value is required. If job will only be started manually, this field is not necessary.
Type:String
maxTags
The maximum number of tags to display in the dropdown. Any non-number value will default to all.
Type:String
reverseByDate
Check this option so that tags are sorted from the newest to the oldest.

If this option is checked, the Sort Z to A one won't be taken into account.

Type:boolean
reverseByName
Check this option so that tags are displayed in reverse order (sorted Z to A).

Notice that if Sort newest first is checked, this option won't be taken into account.

Type:boolean
description (optional)
Type:String
password
Pass a password to your build. The password entered here is made available to the build in plain text as an environment variable like a string parameter would be. The value will be stored encrypted on the Jenkins controller, similar to passwords in Jenkins configuration.
name
Type:String
defaultValueAsSecret
org.kohsuke.stapler.NoStaplerConstructorException: There's no @DataBoundConstructor on any constructor of class hudson.util.Secret
description (optional)
Type:String
$class: 'PromotedBuildParameterDefinition'
name
Type:String
jobName
Type:String
process
Type:String
description (optional)
Type:String
run
name
Type:String
projectName
Type:String
filter
Values:
ALL
STABLE
SUCCESSFUL
COMPLETED
description (optional)
Type:String
string
name
Type:String
defaultValue (optional)
Type:String
description (optional)
Type:String
trim (optional)
Strip whitespace from the beginning and end of the string.
Type:boolean
text
name
Type:String
defaultValue (optional)
Type:String
description (optional)
Type:String
trim (optional)
Strip whitespace from the beginning and end of the string.
Type:boolean
pipelineTriggers
triggers
Array/List:
Nested choice of objects
githubPush
When Jenkins receives a GitHub push hook, GitHub Plugin checks to see whether the hook came from a GitHub repository which matches the Git repository defined in SCM/Git section of this job. If they match and this option is enabled, GitHub Plugin triggers a one-time polling on GITScm. When GITScm polls GitHub, it finds that there is a change and initiates a build. The last sentence describes the behavior of Git plugin, thus the polling and initiating the build is not a part of GitHub plugin.
$class: 'PeriodicFolderTrigger'

Some kinds of folders are reindexed automatically and immediately upon receipt of an external event. For example, a multi-branch project will recheck its SCM repository for new or removed or modified branches when it receives an SCM change notification. (Push notification may be configured as per the SCM plugin used for each respective branch source.) Such notifications can occasionally be unreliable, however, or Jenkins might not even be running to receive them. In some cases no immediate notification is even possible, for example because Jenkins is behind a firewall and can only poll an external system.

This trigger allows for a periodic fallback, but when necessary. If no indexing has been performed in the specified interval, then an indexing will be scheduled. For example, in the case of a multi-branch project, if the source control system is not configured for push notification, set a short interval (most people will pick between 15 minutes and 1 hour). If the source control system is configured for push notification, set an interval that corresponds to the maximum acceptable delay in the event of a lost push notification as the last commit of the day. (Subsequent commits should trigger indexing anyway and result in the commit being picked up, so most people will pick between 4 hours and 1 day.)

interval

The maximum amount of time since the last indexing that is allowed to elapse before an indexing is triggered. For example: interval('5m') // or '2h', '7d', '5000ms', '60s'

Type:String
$class: 'PromotionTrigger'
jobName
Type:String
process
Type:String
upstream

Set up a trigger so that when some other projects finish building, a new build is scheduled for this project. This is convenient for running an extensive test after a build is complete, for example.

This configuration complements the "Build other projects" section in the "Post-build Actions" of an upstream project, but is preferable when you want to configure the downstream project.

upstreamProjects
Type:String
threshold (optional)
Type:String
pollSCM
Configure Jenkins to poll changes in SCM.

Note that this is going to be an expensive operation for CVS, as every polling requires Jenkins to scan the entire workspace and verify it with the server. Consider setting up a "push" trigger to avoid this overhead, as described in this document

scmpoll_spec
Type:String
ignorePostCommitHooks (optional)
Ignore changes notified by SCM post-commit hooks.

This can be useful if you want to prevent some long-running jobs (e.g. reports) starting because of every commit, but still want to run them periodic if SCM changes have occurred.

Note that this option needs to be supported by the SCM plugin, too! The subversion-plugin supports this since version 1.44.

Type:boolean
cron
Provides a cron-like feature to periodically execute this project.

This feature is primarily for using Jenkins as a cron replacement, and it is not ideal for continuously building software projects. When people first start continuous integration, they are often so used to the idea of regularly scheduled builds like nightly/weekly that they use this feature. However, the point of continuous integration is to start a build as soon as a change is made, to provide a quick feedback to the change. To do that you need to hook up SCM change notification to Jenkins.

So, before using this feature, stop and ask yourself if this is really what you want.

spec
Type:String
preserveStashes
Preserve the stashes from the most recent completed builds of this project. This allows a restarted Declarative Pipeline to reuse a stash from the build it was restarted from.
buildCount (optional)
Type:int
$class: 'RequiredResourcesProperty'
resourceNames

When a build is scheduled, it will attempt to lock the specified resources. If some (or all) the resources are already locked by another build, the build will be queued until they are released. It is possible to specify an amount for requested resources below.

Type:String
resourceNamesVar

Name for the Jenkins variable to store the reserved resources in. Leave empty to disable.

Type:String
resourceNumber

Number of resources to request, empty value or 0 means all.
This is useful, if you have a pool of similar resources, from which you want one or more to be reserved.

Type:String
labelName

If you have created a pool of resources, i.e. a label, you can take it into use here. The build will select the resource(s) from the pool that includes all resources sharing the given label. Only one of Label, Groovy Expression or Resources fields may be specified.

Type:String
resourceMatchScript

You can specify a groovy expression to be evaluated each time a resource is checked to be appropriate for a build. The expression must result into a boolean value. The following variables are available, in addition to optional arguments of the currently evaluated build:

resourceName
as per resource configuration
resourceDescription
as per resource configuration
resourceLabels
java.util.List<String> of labels as per resource configuration

For matrix jobs, axis names and axis values can be referenced as well. Examples:

  • resourceLabels.contains("hardcoded")
  • resourceLabels.contains(axisName)
  • resourceName == axisName

The script's contents need to pass approval by the Script Security Plugin.

Nested object
script
Type:String
sandbox
If checked, run this Groovy script in a sandbox with limited abilities. If unchecked, and you are not a Jenkins administrator, you will need to wait for an administrator to approve the script.
Type:boolean
classpath
Additional classpath entries accessible from the script.
Array/List:
Nested object
path
A path or URL to a JAR file. This path should be approved by an administrator or a user with the RUN_SCRIPT permission, or the script fails. If the file or files are once approved, they are treated approved even located in another path.
Type:String
oldPath (optional)
Type:String
shouldBeApproved (optional)
Type:boolean
oldScript (optional)
Type:String
throttleJobProperty

Note that the Throttle Concurrent Builds configuration here does not work for Pipeline jobs.

For that, use the throttle step.

maxConcurrentPerNode

The maximum number of concurrent builds of this project (or category) to be allowed to run per node.

Type:int
maxConcurrentTotal

The maximum number of concurrent builds of this project (or category) to be allowed to run at any one time, across all nodes.

Type:int
categories

Categories can be used to throttle multiple projects.

Categories can be optionally configured with pairs of throttled Jenkins node labels.
Pairs can make each maximum applicable to nodes with matching labels only.
That is achieved by adding such Maximum Per Labeled Node pair(s) to any category.
Category's Maximum Concurrent Builds Per Node is superseded by matching-pair's maximum.

Array/List:
Type:String
throttleEnabled
Type:boolean
throttleOption
Type:String
limitOneJobWithMatchingParams

If this box is checked, only one instance of the job with matching parameter values will be allowed to run at a given time. Other instances of this job with different parameter values will be allowed to run concurrently.

Optionally, provide a comma- or whitespace-separated list of parameters to use when comparing jobs. If blank, all parameters must match for a job to be limited to one running instance.

Type:boolean
paramsToUseForLimit
Type:String
matrixOptions
Nested object
throttleMatrixBuilds
Type:boolean
throttleMatrixConfigurations
Type:boolean
rateLimitBuilds
throttle
Enforces a minimum time between builds based on the desired maximum rate.
Note: this does not enforce an "average" rate, it only looks at the time since last build.
Nested object
count
Type:int
durationName
Type:String
userBoost
Type:boolean
publishChecks: Publish customized checks to SCM platforms
actions (optional)
Array/List:
Nested object
label
The label to be displayed on the checks report for this action.
Type:String
identifier
The unique identifier for the action. Since for SCM platforms like GitHub, this is the only field that would be sent back to your Jenkins instance when an action is requested, so you may need to use this field to have more information besides the basic type of the action.
Type:String
description (optional)
Detailed description of the action's purpose, functionality, and so on.
Type:String
annotations (optional)
Array/List:
Nested object
path
Path to the file to be annotated, started from the project root directory.
Type:String
startLine
Start line of code to be annotated.
Type:int
endLine
End line of code to be annotated.
Type:int
message
A digest message of the annotation.
Type:String
annotationLevel (optional)
Severity level of the annotation, can be one of can be "NOTICE", "WARNING", or "FAILURE"; by default, "WARNING" will be used.
Values:
NONE
NOTICE
WARNING
FAILURE
endColumn (optional)
End column of code to be annotated.
Type:int
rawDetails (optional)
Raw details of the annotation.
Type:String
startColumn (optional)
Start column of code to be annotated.
Type:int
title (optional)
Title of the annotation.
Type:String
conclusion (optional)
The conclusion of the check, can be "ACTION_REQUIRED", "SKIPPED", "CANCELED", "TIME_OUT", "FAILURE", "NEUTRAL", "SUCCESS" or "NONE". By default, "SUCCESS" will be used. When providing the conclusion other than "NONE", please make sure the status is "COMPLETED".
Values:
NONE
ACTION_REQUIRED
SKIPPED
CANCELED
TIME_OUT
FAILURE
NEUTRAL
SUCCESS
detailsURL (optional)
The URL of the site where full details can be found. When providing this parameter, make sure it is http or https scheme.
Type:String
name (optional)
Name or identifier of the check.
Type:String
status (optional)
The status of the check, can be "QUEUED", "IN_PROGRESS", or "COMPLETED". By default, "COMPLETED" will be used.
Values:
NONE
QUEUED
IN_PROGRESS
COMPLETED
summary (optional)
The summary of the check run. This field supports Markdown.
Type:String
text (optional)
The details of the check. This parameter supports Markdown.
Type:String
title (optional)
The title of the check run.
Type:String
publishHTML: Publish HTML reports
target
Nested object
reportName
The name of the report to display for the build/project, such as "Code Coverage"
Type:String
reportDir
The path to the HTML report directory relative to the workspace.
Type:String
reportFiles
The file(s) to provide links inside the report directory
Type:String
keepAll
If checked, archive reports for all successful builds, otherwise only the most recent
Type:boolean
alwaysLinkToLastBuild
If this control and "Keep past HTML reports" are checked, publish the link on project level even if build failed.
Type:boolean
allowMissing
If checked, will allow report to be missing and build will not fail on missing report
Type:boolean
escapeUnderscores (optional)
If checked, underscores in the report title will be escaped to '_5f' when stored on disk. If unchecked, they will not be escaped.
Type:boolean
includes (optional)
Type:String
reportTitles (optional)
The optional title(s) for the report files, which will be used as the tab names. If this is not provided, file names will be used instead.
Type:String
publishIssues: Publish issues created by a static analysis scan
issues
Array/List:
org.kohsuke.stapler.NoStaplerConstructorException: There's no @DataBoundConstructor on any constructor of class io.jenkins.plugins.analysis.core.steps.AnnotatedReport
failOnError (optional)
If there are errors while scanning the console log or files for issues (e.g., file pattern matches no files, source files could not be copied, etc.) then the warning plugin will show these errors in a separate view but does not alter the build state. If you would rather like to fail the build on such errors, please tick this checkbox.
Type:boolean
failedNewAll (optional)
Type:int
failedNewHigh (optional)
Type:int
failedNewLow (optional)
Type:int
failedNewNormal (optional)
Type:int
failedTotalAll (optional)
Type:int
failedTotalHigh (optional)
Type:int
failedTotalLow (optional)
Type:int
failedTotalNormal (optional)
Type:int
healthy (optional)
The healthy threshold defines the limit of warnings for a healthy result: A build is considered as 100% healthy when the number of issues is less than the specified threshold. Values less or equal zero are ignored. So if you want to have a healthy build (i.e. 100%) only for zero warnings, then set this field to 1.
Type:int
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression \p{Alnum}[\p{Alnum}-_]*). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
ignoreFailedBuilds (optional)
This option determines if failed builds should be selected as baseline or not. It is enabled by default, since analysis results might be inaccurate if the build failed. If unchecked, every build that contains a static analysis result is considered, even if the build failed.
Type:boolean
ignoreQualityGate (optional)

If this option is set, only those issues are marked as new, that have been introduced in the current build. Previously new issues in older builds will be converted to outstanding issues. I.e. if someone starts a new build manually (without source code changes), then no new issues will be in the job anymore.

By default, this option is disabled: then a build is selected as reference that passed all quality gates. As soon as a build fails a quality gate, the reference will be frozen until all new issues will be resolved again. That means, that new issues will be aggregated from build to build until the original reason for the failure and all those additional new issues have been resolved. This helps much more to keep your project clean: as soon as there are issues, Jenkins will mark all builds as unstable until the issues have been resolved.

Type:boolean
minimumSeverity (optional)
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
publishAllIssues (optional)
Type:boolean
qualityGates (optional)
Array/List:
Nested object
threshold
The threshold defines the minimum number of warnings that will fail a build. Values less or equal zero are ignored. So if you want to fail a build that has one warning, set this field to 1.
Type:int
type
In order to simplify the user interface you can select the property that will be compared with the specified threshold. Basically, three different properties are available:
Total
Selects the total number of issues in the current build.
New
Selects the total number of new issues in the current build with respect to the reference build. New issues will be calculated by a sophisticated algorithm, that tries to track issues from build to build, even if the source code has been modified. Note that this algorithm sometimes detects outstanding warnings as new, e.g., if a source file has been refactored heavily.
Delta
Selects the difference of the total number of issues of the current build subtracted by the total number of issues in the reference build. This is a simple subtraction, so if you have a build that adds a new warning and removes a completely different warning, then the result will be zero.
Additionally, you can select to choose all issues, or issues of a given severity only (error, high, normal or low).
Values:
TOTAL
TOTAL_ERROR
TOTAL_HIGH
TOTAL_NORMAL
TOTAL_LOW
NEW
NEW_ERROR
NEW_HIGH
NEW_NORMAL
NEW_LOW
DELTA
DELTA_ERROR
DELTA_HIGH
DELTA_NORMAL
DELTA_LOW
unstable
Type:boolean
referenceBuildId (optional)
Type:String
referenceJobName (optional)
Type:String
skipPublishingChecks (optional)
If this option is unchecked, then the plugin automatically publishes the issues to corresponding SCM hosting platforms. For example, if you are using this feature for a GitHub organization project, the warnings will be published to GitHub through the Checks API. If this operation slows down your build or you don't want to publish the warnings to SCM platforms, you can use this option to deactivate this feature.
Type:boolean
sourceCodeEncoding (optional)
In order to correctly show all your affected source code files in the detail views, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
trendChartType (optional)
If there is more than one static analysis result available then an aggregation trend chart will be shown on the project page that shows the analysis results in a single trend chart. You can choose the position of this aggregation trend:
AGGREGATION_TOOLS
The aggregation trend is shown before all other analysis tool trend charts.
TOOLS_AGGREGATION
The aggregation trend is shown after all other analysis tool trend charts.
TOOLS_ONLY
The aggregation trend is not shown, only the analysis tool trend charts are shown.
AGGREGATION_ONLY
The aggregation trend is only shown, no other analysis tool trend charts are shown.
NONE
Neither the aggregation trend nor analysis tool trend charts are shown.
Values:
AGGREGATION_TOOLS
TOOLS_AGGREGATION
TOOLS_ONLY
AGGREGATION_ONLY
NONE
unhealthy (optional)
The unhealthy threshold defines the limit of warnings for an unhealthy result: A build is considered as unhealthy (i.e. 0% health) when the number of issues is greater than the specified threshold. Values less or equal zero are ignored. So if you want to have a build health of 0% starting with 10 issues, then set this field to 9.
Type:int
unstableNewAll (optional)
Type:int
unstableNewHigh (optional)
Type:int
unstableNewLow (optional)
Type:int
unstableNewNormal (optional)
Type:int
unstableTotalAll (optional)
Type:int
unstableTotalHigh (optional)
Type:int
unstableTotalLow (optional)
Type:int
unstableTotalNormal (optional)
Type:int
pwd: Determine current directory
Returns the current directory path as a string.
tmp (optional)
If selected, return a temporary directory associated with the current directory path rather than the directory path itself. The return value is different for each current directory. No two directories share the same temporary directory. This is an appropriate place to put temporary files which should not clutter a source checkout; local repositories or caches; etc. Defaults to false.
Type:boolean
pwsh: PowerShell Core Script
script
Executes a PowerShell script. Multiple lines allowed. This plugin supports PowerShell Core 6+.
Note: be aware of the differences between Windows PowerShell and PowerShell Core, check which one is available on your agents.
Type:String
encoding (optional)
Encoding of process output. In the case of returnStdout, applies to the return value of this step; otherwise, or always for standard error, controls how text is copied to the build log. If unspecified, uses the system default encoding of the node on which the step is run. If there is any expectation that process output might include non-ASCII characters, it is best to specify the encoding explicitly. For example, if you have specific knowledge that a given process is going to be producing UTF-8 yet will be running on a node with a different system encoding (typically Windows, since every Linux distribution has defaulted to UTF-8 for a long time), you can ensure correct output by specifying: encoding: 'UTF-8'
Type:String
label (optional)
Label to be displayed in the pipeline step view and blue ocean details for the step instead of the step type. So the view is more meaningful and domain specific instead of technical.
Type:String
returnStatus (optional)
Normally, a script which exits with a nonzero status code will cause the step to fail with an exception. If this option is checked, the return value of the step will instead be the status code. You may then compare it to zero, for example.
Type:boolean
returnStdout (optional)
If checked, standard output from the task is returned as the step value as a String, rather than being printed to the build log. (Standard error, if any, will still be printed to the log.) You will often want to call .trim() on the result to strip off a trailing newline.
Type:boolean
readCSV: Read content from a CSV file in the workspace.

Reads a file in the current working directory or a String as a plain text. A List of CSVRecord instances is returned

Example:

def records = readCSV file: 'dir/input.csv'
assert records[0][0] == 'key'
assert records[1][1] == 'b'

def content = readCSV text: 'key,value\na,b'
assert records[0][0] == 'key'
assert records[1][1] == 'b'
	

Advanced Example:

def excelFormat = CSVFormat.EXCEL
def records = readCSV file: 'dir/input.csv', format: excelFormat
assert records[0][0] == 'key'
assert records[1][1] == 'b'

def content = readCSV text: 'key,value\na,b', format: CSVFormat.DEFAULT.withHeader()
assert records[1].get('key') == 'a'
assert records[1].get('value') == 'b'
	

file (optional)

Path to a file in the workspace from which to read the CSV data. Data is accessed as a List of String Arrays.

You can only specify file or text, not both in the same invocation.

Type:String
format (optional)
org.kohsuke.stapler.NoStaplerConstructorException: There's no @DataBoundConstructor on any constructor of class org.apache.commons.csv.CSVFormat
text (optional)

A string containing the CSV formatted data. Data is accessed as a List of String Arrays.

You can only specify file or text, not both in the same invocation.

Type:String
readFile: Read file from workspace
Reads a file from a relative path (with root in current directory, usually workspace) and returns its content as a plain string.
file
Relative (/-separated) path to file within a workspace to read.
Type:String
encoding (optional)
The encoding to use when reading the file. If left blank, the platform default encoding will be used. Binary files can be read into a Base64-encoded string by specifying "Base64" as the encoding.
Type:String
readJSON: Read JSON from files in the workspace.

Reads a file in the current working directory or a String as a plain text JSON file. The returned object is a normal Map with String keys or a List of primitives or Map.

Example:

def props = readJSON file: 'dir/input.json'
assert props['attr1'] == 'One'
assert props.attr1 == 'One'

def props = readJSON text: '{ "key": "value" }'
assert props['key'] == 'value'
assert props.key == 'value'

def props = readJSON text: '[ "a", "b"]'
assert props[0] == 'a'
assert props[1] == 'b'

def props = readJSON text: '{ "key": null, "a": "b" }', returnPojo: true
assert props['key'] == null
props.each { key, value ->
    echo "Walked through key $key and value $value"
}
	

file (optional)

Path to a file in the workspace from which to read the JSON data. Data could be access as an array or a map.

You can only specify file or text, not both in the same invocation.

Type:String
returnPojo (optional)

Transforms the output into a POJO type (LinkedHashMap or ArrayList) before returning it.

By default deactivated (false), and a JSON object (JSONObject or JSONArray from json-lib) is returned.

Type:boolean
text (optional)

A string containing the JSON formatted data. Data could be access as an array or a map.

You can only specify file or text, not both in the same invocation.

Type:String
readManifest: Read a Jar Manifest

Reads a Jar Manifest file or text and parses it into a set of Maps. The returned data structure has two properties: main for the main attributes, and entries containing each individual section (except for main).

Example:

            def man = readManifest file: 'target/my.jar'
            assert man.main['Version'] == '6.15.8'
            assert man.main['Application-Name'] == 'My App'
            assert man.entries['Section1']['Key1'] == 'value1-1'
            assert man.entries['Section2']['Key2'] == 'value2-2'
        

file (optional)

Optional path to a file to read. It could be a plain text, .jar, .war or .ear. In the latter cases the manifest will be extracted from the archive and then read.

You can only specify file or text, not both in the same invocation.

Type:String
text (optional)

Optional text containing the manifest data.

You can only specify file or text, not both in the same invocation.

Type:String
readMavenPom: Read a maven project file.

Reads a Maven project file. The returned object is a Model .

Avoid using this step and writeMavenPom. It is better to use the sh step to run mvn goals. For example:


def version = sh script: 'mvn help:evaluate -Dexpression=project.version -q -DforceStdout', returnStdout: true
file (optional)

Optional path to the file to read. If left empty the step will try to read pom.xml in the current working directory.

Type:String
readProperties: Read properties from files in the workspace or text.

Reads a file in the current working directory or a String as a plain text Java Properties file. The returned object is a normal Map with String keys. The map can also be pre loaded with default values before reading/parsing the data.

Fields:
  • file: Optional path to a file in the workspace to read the properties from. These are added to the resulting map after the defaults and so will overwrite any key/value pairs already present.
  • text: An Optional String containing properties formatted data. These are added to the resulting map after file and so will overwrite any key/value pairs already present.
  • defaults: An Optional Map containing default key/values. These are added to the resulting map first.
  • interpolate: Flag to indicate if the properties should be interpolated or not. In case of error or cycling dependencies, the original properties will be returned.

Example:

        def d = [test: 'Default', something: 'Default', other: 'Default']
        def props = readProperties defaults: d, file: 'dir/my.properties', text: 'other=Override'
        assert props['test'] == 'One'
        assert props['something'] == 'Default'
        assert props.something == 'Default'
        assert props.other == 'Override'
        
Example with interpolation:
        def props = readProperties interpolate: true, file: 'test.properties'
        assert props.url = 'http://localhost'
        assert props.resource = 'README.txt'
        // if fullUrl is defined to ${url}/${resource} then it should evaluate to http://localhost/README.txt
        assert props.fullUrl = 'http://localhost/README.txt'
        

defaults (optional)
java.lang.UnsupportedOperationException: do not know how to categorize attributes of type java.util.Map<java.lang.Object, java.lang.Object>
file (optional)
Type:String
interpolate (optional)
Type:boolean
text (optional)
Type:String
readTrusted: Read trusted file from SCM
From a multibranch Pipeline project, reads a file from the associated SCM and returns its contents. Unlike the readFile step, no workspace is required. If the associated branch is not trusted, yet the file has been modified from its trusted version, an error is thrown. Thus this step is useful for loading scripts or other files which might otherwise be used to run malicious commands. Like checkout scm, as a convenience it may also be used from a standalone project configured with Pipeline from SCM, in which case there is no security aspect.
path
Relative (slash-separated) path to the file from the SCM root. Thus readTrusted 'subdir/file' is similar to node {checkout scm; readFile 'subdir/file'}.
Type:String
readYaml: Read yaml from files in the workspace or text.

Reads a file in the current working directory or a String as a plain text YAML file. It uses SnakeYAML as YAML processor. The returned objects are standard Java objects like List, Long, String, ...: bool: [true, false, on, off] int: 42 float: 3.14159 list: ['LITE', 'RES_ACID', 'SUS_DEXT'] map: {hp: 13, sp: 5}

Fields:
  • file: Optional path to a file in the workspace to read the YAML datas from.
  • text: An Optional String containing YAML formatted datas. These are added to the resulting object after file and so will overwrite any value already present if not a new YAML document

Examples:
With only one YAML document :

        def datas = readYaml text: """
something: 'my datas'
size: 3
isEmpty: false
"""
        assert datas.something == 'my datas'
        assert datas.size == 3
        assert datas.isEmpty == false
        
With several YAML documents :
        def datas = readYaml text: """
---
something: 'my first document'
---
something: 'my second document'
"""
        assert datas.size() == 2
        assert datas[0].something == 'my first document'
        assert datas[1].something == 'my second document'
        
With file dir/my.yml containing something: 'my datas' :
        def datas = readYaml file: 'dir/my.yml', text: "something: 'Override'"
        assert datas.something == 'Override'
        

file (optional)
Type:String
text (optional)
Type:String
recordIssues: Record compiler warnings and static analysis results
aggregatingResults (optional)
By default, each static analysis result will be recorded as a separate result that is presented as an individual Jenkins Action with separate UI and dashboard. If you rather prefer aggregation of the results into a single result (i.e., single Jenkins Action), then activate this check box. You still can see the distribution of issues grouped by static analysis tool in the UI.
Type:boolean
blameDisabled (optional)
If this option is unchecked, then the plugin automatically shows what revision and author (name and email) last modified the lines of the affected files that contain issues. If this operation slows down your build or you don't want to publish sensitive user data, you can use this option to deactivate this feature.
Type:boolean
enabledForFailure (optional)
By default, static analysis results are only recorded for stable or unstable builds, but not for failed builds: analysis results might be inaccurate if the build failed. If recording should be enabled for failed builds as well then activate this check box.
Type:boolean
failOnError (optional)
If there are errors while scanning the console log or files for issues (e.g., file pattern matches no files, source files could not be copied, etc.) then the warning plugin will show these errors in a separate view but does not alter the build state. If you would rather like to fail the build on such errors, please tick this checkbox.
Type:boolean
failedNewAll (optional)
Type:int
failedNewHigh (optional)
Type:int
failedNewLow (optional)
Type:int
failedNewNormal (optional)
Type:int
failedTotalAll (optional)
Type:int
failedTotalHigh (optional)
Type:int
failedTotalLow (optional)
Type:int
failedTotalNormal (optional)
Type:int
filters (optional)
The created report of issues can be filtered afterwards. You can specify an arbitrary number of include or exclude filters. Currently, there is support for filtering issues by module name, package or namespace name, file name, category or type. Include filters will be combined with or, exclude filters with and. If no filter is defined, then all issues will be published. Filters with empty regular expression will be ignored.
Array/List:
Nested choice of objects
excludeCategory
pattern
Type:String
excludeFile
pattern
Type:String
excludeMessage
pattern
Type:String
excludeModule
pattern
Type:String
excludePackage
pattern
Type:String
excludeType
pattern
Type:String
includeCategory
pattern
Type:String
includeFile
pattern
Type:String
includeMessage
pattern
Type:String
includeModule
pattern
Type:String
includePackage
pattern
Type:String
includeType
pattern
Type:String
forensicsDisabled (optional)
Type:boolean
healthy (optional)
The healthy threshold defines the limit of warnings for a healthy result: A build is considered as 100% healthy when the number of issues is less than the specified threshold. Values less or equal zero are ignored. So if you want to have a healthy build (i.e. 100%) only for zero warnings, then set this field to 1.
Type:int
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression \p{Alnum}[\p{Alnum}-_]*). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
ignoreFailedBuilds (optional)
This option determines if failed builds should be selected as baseline or not. It is enabled by default, since analysis results might be inaccurate if the build failed. If unchecked, every build that contains a static analysis result is considered, even if the build failed.
Type:boolean
ignoreQualityGate (optional)

If this option is set, only those issues are marked as new, that have been introduced in the current build. Previously new issues in older builds will be converted to outstanding issues. I.e. if someone starts a new build manually (without source code changes), then no new issues will be in the job anymore.

By default, this option is disabled: then a build is selected as reference that passed all quality gates. As soon as a build fails a quality gate, the reference will be frozen until all new issues will be resolved again. That means, that new issues will be aggregated from build to build until the original reason for the failure and all those additional new issues have been resolved. This helps much more to keep your project clean: as soon as there are issues, Jenkins will mark all builds as unstable until the issues have been resolved.

Type:boolean
minimumSeverity (optional)
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
publishAllIssues (optional)
Type:boolean
qualityGates (optional)
Array/List:
Nested object
threshold
The threshold defines the minimum number of warnings that will fail a build. Values less or equal zero are ignored. So if you want to fail a build that has one warning, set this field to 1.
Type:int
type
In order to simplify the user interface you can select the property that will be compared with the specified threshold. Basically, three different properties are available:
Total
Selects the total number of issues in the current build.
New
Selects the total number of new issues in the current build with respect to the reference build. New issues will be calculated by a sophisticated algorithm, that tries to track issues from build to build, even if the source code has been modified. Note that this algorithm sometimes detects outstanding warnings as new, e.g., if a source file has been refactored heavily.
Delta
Selects the difference of the total number of issues of the current build subtracted by the total number of issues in the reference build. This is a simple subtraction, so if you have a build that adds a new warning and removes a completely different warning, then the result will be zero.
Additionally, you can select to choose all issues, or issues of a given severity only (error, high, normal or low).
Values:
TOTAL
TOTAL_ERROR
TOTAL_HIGH
TOTAL_NORMAL
TOTAL_LOW
NEW
NEW_ERROR
NEW_HIGH
NEW_NORMAL
NEW_LOW
DELTA
DELTA_ERROR
DELTA_HIGH
DELTA_NORMAL
DELTA_LOW
unstable
Type:boolean
referenceBuildId (optional)
Type:String
referenceJobName (optional)
Type:String
scm (optional)
Type:String
skipBlames (optional)
Type:boolean
skipPublishingChecks (optional)
If this option is unchecked, then the plugin automatically publishes the issues to corresponding SCM hosting platforms. For example, if you are using this feature for a GitHub organization project, the warnings will be published to GitHub through the Checks API. If this operation slows down your build or you don't want to publish the warnings to SCM platforms, you can use this option to deactivate this feature.
Type:boolean
sourceCodeEncoding (optional)
In order to correctly show all your affected source code files in the detail views, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
sourceDirectories (optional)
Some plugins copy source code files to Jenkins' build folder so that these files can be rendered in the user interface together with build results (coverage, warnings, etc.). If these files are not part of the workspace of a build then Jenkins will not show them by default: otherwise sensitive files could be shown by accident. You can provide a list of additional source code directories that are allowed to be shown in Jenkins user interface here. Note, that such a directory must be an absolute path on the agent that executes the build.
Array/List:
Nested object
path
This plugin copies source code files to Jenkins' build folder so that these files can be rendered in the user interface together with the plugin results. If these files are referenced with relative paths then they cannot be found by the plugin. In these cases you need to specify one or more relative paths within the workspace where the plugin can locate them. Alternatively, you can also specify absolute paths if the source code files are stored outside the workspace (in a directory on the agent). All absolute paths must be additionally approved by an administrator in Jenkins' global configuration page.
Type:String
sourceDirectory (optional)
Type:String
tool (optional)
For each static analysis tool a dedicated parser or scanner will be used to read report files or produce issues in any other way. If your tool is not yet supported you can define a new Groovy based parser in Jenkins system configuration. You can reference this new parser afterwards when you select the tool 'Groovy Parser'. Additionally, you provide a new parser within a new small plug-in. If the parser is useful for other teams as well please share it and provide pull requests for the Warnings Next Generation Plug-in and the Analysis Parsers Library.
Nested choice of objects
acuCobol
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
ajc
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
androidLintParser
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
ansibleLint
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
aquaScanner
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
armCc
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
axivionSuite
basedir (optional)
Type:String
credentialsId (optional)
Type:String
id (optional)
Type:String
name (optional)
Type:String
namedFilter (optional)
Type:String
projectUrl (optional)
Type:String
bluepearl
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
brakeman
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
buckminster
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
cadence
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
cargo
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
ccm
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
checkStyle
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
clair
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
clang
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
clangAnalyzer
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
clangTidy
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
cmake
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
codeAnalysis
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
codeChecker
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
codeNarc
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
coolflux
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
cpd
highThreshold (optional)
Type:int
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
normalThreshold (optional)
Type:int
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
cppCheck
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
cppLint
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
cssLint
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
dscanner
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
dart
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
detekt
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
diabC
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
docFx
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
dockerLint
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
doxygen
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link to the results, so choose a short and meaningful name. Allowed elements are characters, digits, dashes and underscores (more precisely, the ID must match the regular expression `\p{Alnum}[\p{Alnum}-_]*`). If you leave the ID field empty, then the built-in default ID of the registered tool will be used.
Type:String
name (optional)
You can override the display name of the tool. This name is used in details views, trend captions, and hyper links. If you leave the name field empty, then the built-in default name of the registered tool will be used.
Type:String
pattern (optional)
Type:String
reportEncoding (optional)
In order to read all characters of your reports correctly, the plugin must open these files with the correct character encoding (UTF-8, ISO-8859-1, etc.). If you leave this field empty then the default encoding of the platform will be used. This might work but is not recommended.
Type:String
skipSymbolicLinks (optional)
Skipping symbolic links is useful when the scanned directory contains links that create a recursive structure. Note that this option may not work on Windows, since symbolic links are not fully supported here.
Type:boolean
drMemory
id (optional)
The results of the selected tool are published using a unique ID (i.e. URL) which must not be already used by another tool in this job. This ID is used as link