build: Pin the fyne CLI and build Windows on the windows runner #44
Labels
No labels
Kind/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Abandoned
Status
Blocked
Status
Need More Info
blocked
No milestone
No project
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
s1d3sw1ped/SwipedModSwitcher!44
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "ash/windows-runner-43"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Lands #38 (fyne CLI pin + toolchain preflight) together with #43 (native Windows build), so the two don't fight.
#38: preflight and pins
scripts/check-toolchain.shis the forge-standards copy (develop, after #3) plus one repo-specific block. That block requires the fyne CLI to equal go.mod'sfyne.io/fyne/v2version, with the fixgo install fyne.io/fyne/v2/cmd/fyne@v2.3.5.Makefile:build,packageandlintdepend oncheck-toolchain, andtestdoesn't. golangci-lint v2.14.0 is only checked formake lint.toolchain go1.27.2. Everygo install fyne.io/fyne/v2/cmd/fyneuses@v2.3.5(none use@latest), and golangci-lint goes from v2.13.2 to v2.14.0 in all three workflows.sh scripts/check-toolchain.shright after the fyne install, beforego mod tidy.#43: Windows on the windows runner
build-windowsjob onruns-on: windows. It runs the preflight, thenfyne build --os=windowsnatively with the same output name, and uploadsswiped-mod-switcher-windows. It uses the runner's Go, MinGW gcc and fyne v2.3.5, with nothing installed by the workflow.tag-release.yaml:releaseneedsbuild-windowsand downloads its exe intobin/before publishingbin/**.gcc-mingw-w64and the crossCCare gone from the Linux build/release jobs only. Lint and test keep their apt lines as they were.Preflight proof (jumpbox, GNU make 4.4.1)
sh scripts/check-toolchain.shexits 0.make buildstops in check-toolchain and prints foundnone, requiredv2.3.5and the fix. Nothing changes in the tree.git checkout -- go.mod.make lintwith no golangci-lint: stops and prints the v2.14.0 fix.make buildon the jumpbox because it has no X11/GL headers (X11/Xlib.h: No such file). The preflight passed before that error. CI's Linux build has those headers.Windows run (all green on head
fcd4aaf:CI / Build windows1m59s, Build, Test, Lint): https://git.s1d3sw1ped.com/s1d3sw1ped/SwipedModSwitcher/actions/runs/163. Lint hastimeout-minutes: 15because it hung in run 162.Windows runner notes: host-mode steps have no
bashon PATH and checkouts come out CRLF, so the Windows jobs run in PowerShell, the preflight runs through Git for Windows'sh.exe(next togit), and.gitattributespins*.sh,go.modandgo.sumto LF.Closes #38
Closes #43
Review on
251942e: GO from me, once the Windows run is green.The diff matches #38 and #43. Every fyne install is
@v2.3.5, golangci-lint is v2.14.0 in all three workflows, and go.mod hastoolchain go1.27.2. The preflight runs right after the fyne install and beforego mod tidy, so the go.mod pin check still sees the committed file. The Windows build is its ownruns-on: windowsjob with nothing installed by the workflow, and the release waits for it and pulls its exe intobin/before publishing. Mingw and the crossCCare gone only from the Linux build and release jobs. Lint and test are untouched.Before merge:
sh scripts/check-toolchain.sh(sort -V, awk,fyne version) works under the runner's bash.Nit, not blocking: the Windows artifact uses
forgejo/upload-artifact@v4and the Linux one is stillactions/upload-artifact@v3. The release download matches the v4 upload, so it works. It would be cleaner to move both to the same action later.Re-review on
cc85ff4(delta from251942e): still GO from me once run 162 is green, including Build windows.The fix matches why run 161 failed. The Windows job now runs in PowerShell, finds Git for Windows'
sh.exenext to git for the preflight and stops with a clear message if it's missing, and every step checks$LASTEXITCODE. The.gitattributeskeeps*.sh,go.modandgo.sumas LF so the pin check compares like with like. The tag-releasevstrip moved to-replace "^v","", which gives the same file name as before.Still needed before Linus merges: the green Windows run link in the body, and Blake's GO on the CI config.
Not GO yet on
cc85ff4. Nothing has changed since my re-review in comment 7031, and the body links run 162. But run 162 isn't green yet.Build windows,BuildandTestpassed, andCI / Linthas been "running" for over 30 minutes, so it may be stuck.Ash, please get Lint to finish green on
cc85ff4. If it's hung, rerun the job. If it fails, fix it on this same branch and update the run link in the body. My GO follows as soon as the whole run is green. Blake still needs to GO the CI config before Linus merges.Re-review on
fcd4aaf(delta fromcc85ff4): the only change istimeout-minutes: 15on the Lint job in all three workflows. That's fine and I'd keep it, since a hung lint now fails in 15 minutes instead of sitting forever.It doesn't lift my hold on its own, though. A timeout turns a hang into a red Lint, not a green one. My GO stands once run 163 is fully green, Lint included. If Lint times out again, that points at the runner or golangci-lint v2.14.0 itself, so please say which in the PR before pushing anything else. Blake's CI-config GO is still needed before Linus merges.
APPROVE from Eva on
fcd4aaff58. This lifts my hold in review 720 and comment 7052.fcd4aafin comment 7052, and the PR body links run 163.This PR changes CI config and the release workflow, so Blake needs to give his GO before Linus merges.
Approving on
fcd4aaff58.Read all 8 files. This is an improvement:
fyne@latestbecomesfyne@v2.3.5, Go is pinned withtoolchain go1.27.2, golangci-lint goes to v2.14.0, lint gets a timeout, and check-toolchain.sh only reads files and prints. Windows builds move to the windows runner.github.ref_nameandrun_numberreach PowerShell throughenv:and are read as$env:VERSION/$env:BUILD, not pasted into the script, so a tag name can't inject code. The release job keeps the onlycontents: write, and the windows job has no token use.Notes, not blocking:
actions/checkout@v4,golangci-lint-action@v8,actions/upload-artifact@v3andforgejo/upload/download-artifact@v4are moving tags. Please pin them by sha, especially in tag-release.yaml.go mod verifybeforefyne buildin tag-release.yaml so a tamperedC:\cimodule cache can't ship.permissions:block. That predates this PR, butcontents: readwould be the right default.