Skip to content

Commit 1da3d8a

Browse files
committed
/deploy: no longer build the MSYS2 runtime packages for both architectures
The purpose of introducing a separate `msys2-runtime-3.3` package is to allow supporting Git for Windows on i686 setups, even though it cannot receive updates to the latest MSYS2 runtime versions any longer because the MSYS2 project dropped i686 support a long time ago. To that end, let's actually build `msys2-runtime-3.3` _only_ for i686, and `msys2-runtime` _only_ for x86_64. That split will allow us to change the `msys2-runtime-3.3` package definition so that it supersedes ("replaces") `msys2-runtime` and automagically updates the 32-bit Git for Windows SDKs out there. This is a step toward phasing out i686 support of Git for Windows, see: git-for-windows/git#4279 (comment) for more details about that plan. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
1 parent 11d7b2d commit 1da3d8a

2 files changed

Lines changed: 19 additions & 12 deletions

File tree

GitForWindowsHelper/slash-commands.js

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -159,10 +159,17 @@ module.exports = async (context, req) => {
159159

160160
const toTrigger = []
161161
if (isMSYSPackage(package_name)) {
162-
toTrigger.push(
163-
{ architecture: 'x86_64' },
164-
{ architecture: 'i686' }
165-
)
162+
if (package_name !== 'msys2-runtime-3.3') {
163+
toTrigger.push(
164+
{ architecture: 'x86_64' }
165+
)
166+
}
167+
168+
if (package_name !== 'msys2-runtime') {
169+
toTrigger.push(
170+
{ architecture: 'i686' }
171+
)
172+
}
166173
} else {
167174
toTrigger.push(
168175
{ displayArchitecture: 'i686/x86_64' }

__tests__/index.test.js

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -411,10 +411,10 @@ testIssueComment('/deploy msys2-runtime', {
411411
expect(await index(context, context.req)).toBeUndefined()
412412
expect(context.res.body).toEqual(`I edited the comment: appended-comment-body-existing comment body
413413
414-
The [x86_64](dispatched-workflow-build-and-deploy.yml) and the [i686](dispatched-workflow-build-and-deploy.yml) workflow runs were started.`)
415-
expect(mockQueueCheckRun).toHaveBeenCalledTimes(2)
416-
expect(mockUpdateCheckRun).toHaveBeenCalledTimes(2)
417-
expect(dispatchedWorkflows.map(e => e.payload.inputs.architecture)).toEqual(['i686', 'x86_64'])
414+
The workflow run [was started](dispatched-workflow-build-and-deploy.yml).`)
415+
expect(mockQueueCheckRun).toHaveBeenCalledTimes(1)
416+
expect(mockUpdateCheckRun).toHaveBeenCalledTimes(1)
417+
expect(dispatchedWorkflows.map(e => e.payload.inputs.architecture)).toEqual(['x86_64'])
418418
})
419419

420420
testIssueComment('/deploy msys2-runtime-3.3', {
@@ -433,10 +433,10 @@ testIssueComment('/deploy msys2-runtime-3.3', {
433433
expect(await index(context, context.req)).toBeUndefined()
434434
expect(context.res.body).toEqual(`I edited the comment: appended-comment-body-existing comment body
435435
436-
The [x86_64](dispatched-workflow-build-and-deploy.yml) and the [i686](dispatched-workflow-build-and-deploy.yml) workflow runs were started.`)
437-
expect(mockQueueCheckRun).toHaveBeenCalledTimes(2)
438-
expect(mockUpdateCheckRun).toHaveBeenCalledTimes(2)
439-
expect(dispatchedWorkflows.map(e => e.payload.inputs.architecture)).toEqual(['i686', 'x86_64'])
436+
The workflow run [was started](dispatched-workflow-build-and-deploy.yml).`)
437+
expect(mockQueueCheckRun).toHaveBeenCalledTimes(1)
438+
expect(mockUpdateCheckRun).toHaveBeenCalledTimes(1)
439+
expect(dispatchedWorkflows.map(e => e.payload.inputs.architecture)).toEqual(['i686'])
440440
})
441441

442442
testIssueComment('/add release note', {

0 commit comments

Comments
 (0)