-
Notifications
You must be signed in to change notification settings - Fork 155
/
Copy pathasciidoctor-web-pdf.yml
90 lines (85 loc) · 2.49 KB
/
asciidoctor-web-pdf.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
---
title: "Bump Asciidoctor-Web-PDF version"
scms:
default:
kind: github
spec:
user: "{{ .github.user }}"
email: "{{ .github.email }}"
owner: "{{ requiredEnv .github.owner }}"
repository: "{{ requiredEnv .github.repository }}"
token: "{{ requiredEnv .github.token }}"
username: "{{ .github.username }}"
branch: "{{ .github.branch }}"
sources:
latestVersion:
kind: githubRelease
name: "Get the latest Asciidoctor-Web-PDF version"
spec:
owner: "Mogztter"
repository: "asciidoctor-web-pdf"
token: "{{ requiredEnv .github.token }}"
username: "{{ .github.username }}"
versionFilter:
kind: latest
transformers:
- trimPrefix: "v"
conditions:
testDockerfileArgVersion:
name: "Does the Dockerfile have an ARG instruction which key is asciidoctor_web_pdf_version?"
kind: dockerfile
spec:
file: Dockerfile
instruction:
keyword: "ARG"
matcher: "asciidoctor_web_pdf_version"
testVersionInReadme:
name: "Does the README.adoc have a variable asciidoctor_web_pdf_version"
kind: file
spec:
file: README.adoc
matchPattern: '(?m:^:ASCIIDOCTOR_WEB_PDF_VERSION:.*)'
testVersionInTestHarness:
name: "Does the test harness have variable ASCIIDOCTOR_WEB_PDF_VERSION"
kind: file
spec:
file: tests/asciidoctor.bats
matchPattern: '(?m:^ASCIIDOCTOR_WEB_PDF_VERSION=.*)'
targets:
updateDockerfile:
name: "Update the value of ARG asciidoctor_web_pdf_version in the Dockerfile"
kind: dockerfile
spec:
file: Dockerfile
instruction:
keyword: "ARG"
matcher: "asciidoctor_web_pdf_version"
scmID: default
updateTestHarness:
name: "Update the key ASCIIDOCTOR_WEB_PDF_VERSION in the test harness"
kind: file
spec:
file: tests/asciidoctor.bats
matchPattern: '(?m:^ASCIIDOCTOR_WEB_PDF_VERSION=.*)'
content: 'ASCIIDOCTOR_WEB_PDF_VERSION={{ source `latestVersion` }}'
scmID: default
updateReadme:
name: "Update the key ASCIIDOCTOR_WEB_PDF_VERSION in the README.adoc file"
kind: file
spec:
file: README.adoc
matchPattern: '(?m:^:ASCIIDOCTOR_WEB_PDF_VERSION:.*)'
content: ':ASCIIDOCTOR_WEB_PDF_VERSION: {{ source `latestVersion` }}'
scmID: default
pullrequests:
default:
kind: github
scmID: default
targets:
- updateDockerfile
- updateTestHarness
- updateReadme
spec:
labels:
- chore
- dependencies