Skip to content

Commit b33586f

Browse files
committed
/deploy: use separate check runs for each architecture
For MSys packages we start two build workflows, that can succeed or fail independently from one another. Representing their combined outcome in one check run, whose result only depends on the first workflow to finish is not great. Using one check run for each workflow makes it easier to see which workflow failed when one of them fails and allows us to see at a glance if one of the workflows is still running after the other one completed. Signed-off-by: Matthias Aßhauer <mha1993@live.de>
1 parent 01a9475 commit b33586f

1 file changed

Lines changed: 34 additions & 12 deletions

File tree

GitForWindowsHelper/slash-commands.js

Lines changed: 34 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -134,17 +134,6 @@ module.exports = async (context, req) => {
134134
await thumbsUp()
135135

136136
const { queueCheckRun } = require('./check-runs')
137-
await queueCheckRun(
138-
context,
139-
await getToken(),
140-
'git-for-windows',
141-
repo,
142-
ref,
143-
'deploy',
144-
`Build and deploy ${package_name}`,
145-
`Deploying ${package_name}`
146-
)
147-
148137
const triggerWorkflowDispatch = require('./trigger-workflow-dispatch')
149138
const triggerBuild = async (architecture) =>
150139
await triggerWorkflowDispatch(
@@ -173,10 +162,43 @@ module.exports = async (context, req) => {
173162
text
174163
)
175164
if (!isMSYSPackage(package_name)) {
165+
await queueCheckRun(
166+
context,
167+
await getToken(),
168+
'git-for-windows',
169+
repo,
170+
ref,
171+
'deploy',
172+
`Build and deploy ${package_name}`,
173+
`Deploying ${package_name}`
174+
)
175+
176176
const answer = await triggerBuild()
177177
const answer2 = await appendToComment(`The workflow run [was started](${answer.html_url})`)
178178
return `I edited the comment: ${answer2.html_url}`
179179
}
180+
181+
await queueCheckRun(
182+
context,
183+
await getToken(),
184+
'git-for-windows',
185+
repo,
186+
ref,
187+
'deploy_x86_64',
188+
`Build and deploy ${package_name}`,
189+
`Deploying ${package_name}`
190+
)
191+
await queueCheckRun(
192+
context,
193+
await getToken(),
194+
'git-for-windows',
195+
repo,
196+
ref,
197+
'deploy_i686',
198+
`Build and deploy ${package_name}`,
199+
`Deploying ${package_name}`
200+
)
201+
180202
const x86_64Answer = await triggerBuild('x86_64')
181203
const i686Answer = await triggerBuild('i686')
182204
const answer2 = await appendToComment(
@@ -262,4 +284,4 @@ module.exports = async (context, req) => {
262284
}
263285

264286
return `Ignoring slash command ${command} in ${commentURL}`
265-
}
287+
}

0 commit comments

Comments
 (0)