Whenever GitRepo
is used in a step, a set of environment variables is automatically made available that you can use in your step.
Environment Variable | Description |
---|---|
res_<resource_name>_path | Relative path of the resource |
res_<resource_name>_branchName | Name of branch on which the commit occurred. If it was created for a pull request, this is the base branch. This environment variable is useful for getting the name of the branch. |
res_<resource_name>_commitMessage | Commit message of the version being used |
res_<resource_name>_commitSha | SHA of the commit of the version being used |
res_<resource_name>_commitUrl | URL to the commit |
res_<resource_name>_committerLogin | Name of the committer for the SHA being used |
res_<resource_name>_gitProvider_name | Git integration name |
res_<resource_name>_gitProvider_url | URL of the Git Provider integration |
res_<resource_name>_gitRepoFullName | Name of the Git repo |
res_<resource_name>_gitRepoRepositoryHttpsUrl | HTTPS URL for the Git repository |
res_<resource_name>_gitRepoRepositorySshUrl | SSH URL for the Git repository. |
res_<resource_name>_gitRepoRepositoryUrl | URL for the Git repository |
res_<resource_name>_gitRepoSourceDefaultBranch | Default branch of the Git repository |
res_<resource_name>_gitTagName | If a tag name was present in the current version, this will be the tag name |
res_<resource_name>_integrationName | The |
res_<resource_name>_isGitTag |
|
res_<resource_name>_isPrerelease | True if the version is a git release based build. Supported only if the integration is GitHub |
res_<resource_name>_isPullRequest |
|
res_<resource_name>_isPullRequestClose |
|
res_<resource_name>_isRelease |
|
res_<resource_name>_pullRequestNumber | The ID number of the pull request |
res_<resource_name>_pullRequestBaseBranch | Name of the base branch into which the pull request changes will be merged |
res_<resource_name>_pullRequestSourceUrl | Source URL of the pull request |
res_<resource_name>_pullRequestSourceHttpsUrl | Source HTTPS URL of the pull request |
res_<resource_name>_pullRequestSourceSshUrl | Source SSH URL of the pull request |
res_<resource_name>_resourcePath | Full path of the resource folder on the node TipTo mount a folder to a pipeline runtime step, you can add a GitRepo resource in your pipeline configuration. After the GitRepo resource is defined, you can reference it within your pipeline step using |
res_<resource_name>_operation | Input or output resource |
res_<resource_name>_shaData | JSON object containing the details of the SHA |
res_<resource_name>_beforeCommitSha | SHA before the commit was made |
res_<resource_name>_baseCommitRef | The commit SHA of base branch in a PR |
res_<resource_name>_headCommitRef | The source branch name in a PR |
res_<resource_name>_compareUrl | Compare URL for the commit |
res_<resource_name>_gitTagMessage | If a git tag is created, this holds the message if it is present |
res_<resource_name>_releaseName | If a release is created, this holds the name of the release |
res_<resource_name>_releaseBody | If a release is created, this holds the description of the release |
res_<resource_name>_releasedAt | If a release is created, this holds the date of the release |
res_<resource_name>_lastAuthorLogin | Details of when the last author logged in |
res_<resource_name>_lastAuthorEmail | Email of the author |
res_<resource_name>_isBranchCreate |
|
res_<resource_name>_isBranchDelete |
|