This repository has been archived by the owner on Sep 1, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
/
config.yml
244 lines (236 loc) · 7.4 KB
/
config.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
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
title: Connect the dots in a GitHub repository
description: This course will teach you skills for finding relevant conversations, commits, and projects in a repository.
template:
name: connect-the-dots-in-a-github-repository
repo: connect-the-dots-in-a-github-repository-template
before:
- type: createIssue
title: Welcome
body: 00_welcome-issue.md
- type: createIssue
title: Welcome to this repository
body: 00_existing-welcome.md
- type: createPullRequest
title: Create documentation structure
body: 00_create-documentation-structure.md
head: create-documentation-structure
- type: mergeBranch
head: create-documentation-structure
- type: deleteBranch
branch: create-documentation-structure
- type: createPullRequest
title: Add new pages
body: 00_add-new-pages.md
head: add-new-pages
- type: mergeBranch
head: add-new-pages
- type: deleteBranch
branch: add-new-pages
- type: createPullRequest
title: Add navigation
body: 00_add-navigation.md
head: add-navigation
- type: mergeBranch
head: add-navigation
- type: deleteBranch
branch: add-navigation
- type: createPullRequest
title: Add Git tips
body: 00_add-git-tips.md
head: add-git-tips
action_id: gitTipsPR
- type: createStatus
state: "failure"
failure:
description: >-
Please make sure that all words are spelled correctly.
sha: ab8fe26dfd24d863908a5074e704358023d11109
context: failing-build
steps:
# Step 1:
- title: References within issues
description: Find and close the duplicate cross-linked issue
event: issues.closed
link: '{{ repoUrl }}/issues/1'
actions:
- type: gate
left: '%payload.issue.title%'
operator: ===
right: Welcome to this repository
else:
- type: respond
with: e-unexpected.md
data:
expected: close the issue titled **Welcome to this repository**
- type: createIssue
title: Fix the sidebar
body: 01_sidebar.md
comments:
- 01_crosslink.md
action_id: similarIssue
- type: createProjectBoard
name: v1.0.0
description: Planning for v1.0.0 release
columns:
- Backlog
- In progress
action_id: projectBoard
- type: octokit
method: projects.createColumn
project_id: '%actions.projectBoard.data.id%'
name: Done
owner: '%payload.repository.owner.login%'
repo: '%payload.repository.name%'
action_id: doneColumn
- type: octokit
method: projects.createCard
owner: '%payload.repository.owner.login%'
repo: '%payload.repository.name%'
content_id: '%actions.similarIssue.data.id%'
content_type: Issue
column_id: '%actions.doneColumn.data.id%'
- type: createIssue
title: Broken sidebar
body: 01_the-similar-crosslink.md
- type: closeIssue
issue: Welcome
- type: respond
with: 01_next-step.md
- type: respond
with: 01_next-step.md
issue: Welcome
# Step 2: Crosslink
- title: Create a crosslink
description: Find the relevant or duplicate issue or pull request, and create a crosslink
event: issue_comment.created
link: '{{ repoUrl }}/issues/7'
actions:
- type: gate
every: true
gates:
- left: '%payload.issue.title%'
operator: ===
right: Fix the sidebar
- left: '(8)'
operator: test
right: '%payload.comment.body%'
else:
- type: respond
with: e-unexpected.md
data:
expected: comment on the issue titled **Fix the sidebar** with the comment `#8`, the number of the similar issue
- type: respond
with: 02_find-commit.md
# Step 3:
- title: Find a commit
description: Find the commit associated with the creation of the sidebar file
event: issue_comment.created
link: '{{ repoUrl }}/issues/7'
actions:
- type: gate
every: true
gates:
- left: '%payload.issue.title%'
operator: ===
right: Fix the sidebar
- left: '(312f87)'
operator: test
right: '%payload.comment.body%'
else:
- type: respond
with: e-unexpected.md
data:
expected: comment on the issue titled **Fix the sidebar** with the comment `312f872f79e50d505f02be5ddc97b3f7504d0189`, the SHA of the commit we're looking for
- type: respond
with: 03_context.md
data:
commitId: '%payload.comment.body%'
# Step 4: Finding info and context
- title: Find context
description: Create a link to the pull request where the commit was created
event: project_card.created
link: '{{ repoUrl }}/issues/7'
actions:
- type: gate
left: '(5)'
operator: test
right: '%payload.project_card.content_url%'
else:
- type: respond
with: e-unexpected.md
issue: Fix the sidebar
data:
expected: add pull request \#5 to the Done column of the v1.0.0 project
- type: respond
with: 04_find-broken-build.md
issue: Fix the sidebar
# Step 5:
- title: Assign yourself
description: Assign yourself to the pull request with a broken build
event: pull_request.assigned
link: '{{ repoUrl }}/issues/7'
actions:
- type: gate
left: '%payload.pull_request.title%'
operator: ===
right: Add Git tips
else:
- type: respond
with: e-unexpected.md
data:
expected: 'assign yourself to the pull request titled **Add Git tips**'
- type: respond
with: 05_fix-build.md
# Step 6: Something to do with tests
- title: Fix the broken build
description: Fix the broken build in the pull request with a new commit
event: pull_request.synchronize
link: '{{ repoUrl }}/pull/6'
actions:
- type: getFileContents
filename: docs/git-tips.md
action_id: fileContents
- type: gate
every: true
gates:
- left: '%payload.pull_request.title%'
operator: ===
right: Add Git tips
- left: '(tricks)'
operator: test
right: '%actions.fileContents%'
else:
- type: respond
with: e-unexpected.md
data:
expected: edit `docs/git-tips.md` on the `add-git-tips` branch so that the word "tricks" is properly spelled
- type: createStatus
state: success
sha: '%payload.head_commit.id%'
- type: respond
with: 06_please-merge.md
issue: Add Git tips
# Step 7: Merge pull request
- title: Merge
description: Merge the final pull request
event: pull_request.closed
link: '{{ repoUrl }}/pull/6'
actions:
- type: gate
every: true
gates:
- left: '%payload.pull_request.merged%'
- left: '%payload.pull_request.title%'
operator: ===
right: Add Git tips
else:
- type: respond
with: e-unexpected.md
data:
expected: merge the pull request titled **Add Git tips**
- type: createIssue
title: Congratulations!
body: 07_congratulations.md
- type: respond
with: 07_final-issue.md
issue: Add Git tips