diff --git a/updatecli/updatecli.d/golang.yml b/updatecli/updatecli.d/golang.yml new file mode 100644 index 000000000..9de66396a --- /dev/null +++ b/updatecli/updatecli.d/golang.yml @@ -0,0 +1,57 @@ +--- +name: Bump golang version + +scms: + default: + kind: github + spec: + user: "{{ .github.user }}" + email: "{{ .github.email }}" + owner: "{{ .github.owner }}" + repository: "{{ .github.repository }}" + token: "{{ requiredEnv .github.token }}" + username: "{{ .github.username }}" + branch: "{{ .github.branch }}" + +sources: + getGolangVersion: + kind: githubrelease + spec: + owner: golang + repository: go + token: "{{ requiredEnv .github.token }}" + username: "{{ .github.username }}" + versionfilter: + kind: regex + ## Latest stable 1.x.y version + pattern: 'go1\.(\d*)\.(\d*)$' + transformers: + - trimprefix: go + +targets: + updateVersion: + name: "Update the `Golang` version in the tools-versions.yml file" + sourceid: getGolangVersion + kind: yaml + spec: + file: "provisioning/tools-versions.yml" + key: "golang_version" + scmid: default + updateVersionInGoss: + name: Update the `Golang` version in the goss test + kind: yaml + spec: + files: + - goss/goss-linux.yaml + key: $.command.golang.stdout[0] + scmid: default + +actions: + default: + kind: github/pullrequest + title: Bump Golang version to {{ source "getGolangVersion" }} + scmid: default + spec: + labels: + - dependency + - golang