Gitlab Tag
kind: gitlab/tag
On this page
source | condition | target |
---|---|---|
✔ | ✔ | ✗ |
Description
The Gitlab "tag" plugin allows to manipulate Gitlab repository tags.
source
When used as a "source", the Gitlab tag plugin allows to get a Gitlab repository tag according the version filter rule provided.
condition
When used as a "condition". the Gitlab tag plugin allows to test that specific Gitlab tag exist.
target
Target is not supported, feel free to manifest your interest by opening an issue on updatecil/updatecli/issues, or highlighting an existing one.
Parameters
Name | Type | Description | Required |
---|---|---|---|
owner | string | [S][C] Owner specifies repository owner | |
repository | string | [S][C] Repository specifies the name of a repository for a specific owner | |
tag | string | [S] Tag defines the Gitlab tag . | |
token | string | [S][C][T] Token specifies the credential used to authenticate with | |
url | string | [S][C][T] URL specifies the default github url in case of Gitlab enterprise | |
username | string | [S][C][T] Username specifies the username used to authenticate with Gitlab API | |
versionfilter | object | [S][C] VersionFilter provides parameters to specify version pattern and its type like regex, semver, or just latest. | |
kind | string | Specifies the version kind such as semver, regex, or latest | |
pattern | string | Specifies the version pattern according the version kind | |
strict | boolean | Strict enforce strict versioning rule. Only used for semantic versioning at this time |
Example
# updatecli.yaml
name: "Show Gitlab tag usage"
sources:
default:
name: "Get tag using versionfilter from a Gitlab repository"
kind: "gitlab/tag"
spec:
# Default to gitlab.com
# url: "gitlab.com"
owner: "olblak"
repository: "updatecli-test"
versionfilter:
kind: "semver"
pattern: "~0.0"
latest:
name: "Get latest tag tag from a Gitlab repository"
kind: "gitlab/tag"
spec:
# Default to gitlab.com
# url: "gitlab.com"
owner: "olblak"
repository: "updatecli-test"
conditions:
default:
name: "Test tag '0.0.2' exist on the Gitlab repository"
kind: "gitlab/tag"
disablesourceinput: true
spec:
# Default to gitlab.com
# url: "gitlab.com"
owner: "olblak"
repository: "updatecli"
tag: "v0.2.0"
sourcedefault:
name: "Test that the tag retrieved from source 'default' exist on the Gitlab repository"
kind: "gitlab/tag"
sourceid: "default"
spec:
# Default to gitlab.com
# url: "gitlab.com"
owner: "olblak"
repository: "updatecli"
latest:
name: "Test that the tag retrieved from source 'latest' exist on the Gitlab repository"
kind: "gitlab/tag"
sourceid: "latest"
spec:
# Default to gitlab.com
# url: "gitlab.com"
owner: "olblak"
repository: "updatecli"