2019-11-04 17:07:30 +02:00
metadata :
name : githubPublishRelease
description : Publish a release in GitHub
longDescription : |
This step creates a tag in your GitHub repository together with a release.
The release can be filled with text plus additional information like :
2019-11-05 15:46:45 +02:00
2019-11-04 17:07:30 +02:00
* Closed pull request since last release
* Closed issues since last release
* Link to delta information showing all commits since last release
2019-11-05 15:46:45 +02:00
2019-11-04 17:07:30 +02:00
The result looks like
2019-11-05 15:46:45 +02:00
2019-11-04 17:07:30 +02:00
![ Example release](../images/githubRelease.png)
spec :
inputs :
secrets :
2020-01-15 13:16:25 +02:00
- name : githubTokenCredentialsId
description : Jenkins 'Secret text' credentials ID containing token to authenticate to GitHub.
type : jenkins
2019-11-04 17:07:30 +02:00
params :
2020-01-15 13:16:25 +02:00
- name : addClosedIssues
2020-08-31 16:10:28 +02:00
description : "If set to `true`, closed issues and merged pull-requests since the last release will added below the `releaseBodyHeader`"
2020-01-15 13:16:25 +02:00
scope :
2020-08-31 16:10:28 +02:00
- PARAMETERS
- STAGES
- STEPS
2020-01-15 13:16:25 +02:00
type : bool
default : false
- name : addDeltaToLastRelease
2020-11-25 14:35:37 +02:00
description : "If set to `true`, a link will be added to the release information that brings up all commits since the last release."
2020-01-15 13:16:25 +02:00
scope :
2020-08-31 16:10:28 +02:00
- PARAMETERS
- STAGES
- STEPS
2020-01-15 13:16:25 +02:00
type : bool
default : false
- name : apiUrl
aliases :
- name : githubApiUrl
description : Set the GitHub API url.
scope :
2020-08-31 16:10:28 +02:00
- GENERAL
- PARAMETERS
- STAGES
- STEPS
2020-01-15 13:16:25 +02:00
type : string
default : https://api.github.com
mandatory : true
- name : assetPath
description : Path to a release asset which should be uploaded to the list of release assets.
scope :
2020-08-31 16:10:28 +02:00
- PARAMETERS
- STAGES
- STEPS
2020-01-15 13:16:25 +02:00
type : string
2022-04-08 11:29:07 +02:00
- name : assetPathList
description : List of paths to a release asset which should be uploaded to the list of release assets.
scope :
- PARAMETERS
- STAGES
- STEPS
type : "[]string"
2020-01-15 13:16:25 +02:00
- name : commitish
2020-08-31 16:10:28 +02:00
description : "Target git commitish for the release"
2020-01-15 13:16:25 +02:00
scope :
2020-08-31 16:10:28 +02:00
- PARAMETERS
- STAGES
- STEPS
2020-01-15 13:16:25 +02:00
type : string
default : "master"
2022-08-15 09:48:28 +02:00
resourceRef :
- name : commonPipelineEnvironment
param : git/headCommitId
2020-01-15 13:16:25 +02:00
- name : excludeLabels
2020-08-31 16:10:28 +02:00
description : "Allows to exclude issues with dedicated list of labels."
2020-01-15 13:16:25 +02:00
scope :
2020-08-31 16:10:28 +02:00
- PARAMETERS
- STAGES
- STEPS
type : "[]string"
2020-01-15 13:16:25 +02:00
- name : labels
2020-08-31 16:10:28 +02:00
description : "Labels to include in issue search."
2020-01-15 13:16:25 +02:00
scope :
2020-08-31 16:10:28 +02:00
- PARAMETERS
- STAGES
- STEPS
type : "[]string"
2020-01-15 13:16:25 +02:00
- name : owner
aliases :
- name : githubOrg
2020-09-14 12:05:12 +02:00
description : Name of the GitHub organization.
2020-01-15 13:16:25 +02:00
resourceRef :
- name : commonPipelineEnvironment
param : github/owner
scope :
2022-11-02 15:41:15 +02:00
- GENERAL
2020-08-31 16:10:28 +02:00
- PARAMETERS
- STAGES
- STEPS
2020-01-15 13:16:25 +02:00
type : string
mandatory : true
2020-06-15 21:05:08 +02:00
- name : preRelease
2020-08-31 16:10:28 +02:00
description : "If set to `true` the release will be marked as Pre-release."
2020-06-15 21:05:08 +02:00
scope :
2020-08-31 16:10:28 +02:00
- PARAMETERS
- STAGES
- STEPS
2020-06-15 21:05:08 +02:00
type : bool
default : false
2020-01-15 13:16:25 +02:00
- name : releaseBodyHeader
description : Content which will appear for the release.
scope :
2020-08-31 16:10:28 +02:00
- PARAMETERS
- STAGES
- STEPS
2020-01-15 13:16:25 +02:00
type : string
- name : repository
aliases :
- name : githubRepo
2020-09-14 12:05:12 +02:00
description : Name of the GitHub repository.
2020-01-15 13:16:25 +02:00
resourceRef :
- name : commonPipelineEnvironment
param : github/repository
scope :
2022-11-02 15:41:15 +02:00
- GENERAL
2020-08-31 16:10:28 +02:00
- PARAMETERS
- STAGES
- STEPS
2020-01-15 13:16:25 +02:00
type : string
mandatory : true
- name : serverUrl
aliases :
- name : githubServerUrl
2020-08-31 16:10:28 +02:00
description : "GitHub server url for end-user access."
2020-01-15 13:16:25 +02:00
scope :
2020-08-31 16:10:28 +02:00
- GENERAL
- PARAMETERS
- STAGES
- STEPS
2020-01-15 13:16:25 +02:00
type : string
default : https://github.com
mandatory : true
2021-10-19 17:36:17 +02:00
- name : tagPrefix
type : string
description : "Defines a prefix to be added to the tag."
scope :
- PARAMETERS
- STAGES
- STEPS
default : ""
2020-01-15 13:16:25 +02:00
- name : token
aliases :
- name : githubToken
2021-01-27 13:58:47 +02:00
- name : access_token
2020-08-31 16:10:28 +02:00
description : "GitHub personal access token as per https://help.github.com/en/github/authenticating-to-github/creating-a-personal-access-token-for-the-command-line"
2020-01-15 13:16:25 +02:00
scope :
2020-08-31 16:10:28 +02:00
- GENERAL
- PARAMETERS
- STAGES
- STEPS
2020-01-15 13:16:25 +02:00
type : string
mandatory : true
2020-04-16 14:37:45 +02:00
secret : true
2020-08-28 15:38:15 +02:00
resourceRef :
- name : githubTokenCredentialsId
type : secret
2020-12-22 18:57:11 +02:00
- type : vaultSecret
2021-09-21 13:06:32 +02:00
default : github
name : githubVaultSecretName
2020-01-15 13:16:25 +02:00
- name : uploadUrl
aliases :
- name : githubUploadUrl
description : Set the GitHub API url.
scope :
2020-08-31 16:10:28 +02:00
- GENERAL
- PARAMETERS
- STAGES
- STEPS
2020-01-15 13:16:25 +02:00
type : string
default : https://uploads.github.com
mandatory : true
- name : version
2020-08-31 16:10:28 +02:00
description : "Define the version number which will be written as tag as well as release name."
2020-01-15 13:16:25 +02:00
resourceRef :
- name : commonPipelineEnvironment
param : artifactVersion
scope :
2020-08-31 16:10:28 +02:00
- PARAMETERS
- STAGES
- STEPS
2020-01-15 13:16:25 +02:00
type : string
mandatory : true