Repository navigation
fix(oem): install the Framework system tool under its upstream cask name - #1450
Conversation
The Framework OEM Brewfile referenced `cask "ublue-os/tap/framework_tool"` but the upstream cask in ublue-os/homebrew-tap is published as `framework-tool` (with a hyphen). With `set -euo pipefail` active in 20-oem-brew.sh, that mismatch made `brew bundle` exit non-zero on every Framework chassis, which prevented the dconf Framework logo write from running and permanently skipped the framework-wallpapers cask install. The hook is then stuck retrying: every first-login run re-invokes brew bundle, hits the same missing cask, and never records the oem-Framework stamp, so even users who later retry never get the wallpapers or the menu logo. Rename the cask to match what the tap actually publishes, fix the matching references in the OEM hardware hooks skill and the brew-lifecycle placement notes, and add bats coverage that pins both the Framework and ASUS OEM Brewfile cask tokens so this cannot regress silently again. The validate- brewfiles.sh validator only scans the homebrew/ tree, not the oem/ tree, so a targeted test is the right place to lock these tokens. Closes projectbluefin#1449. Assisted-by: Minimax-M3 via Hive Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Hive-Run: projectbluefin#1449 Hive-Plan: issue-1449-framework-oem-branding Hive-Spec: oem-hardware-hooks#framework-cask-tokens Signed-off-by: dtg01100 <dtg01100@users.noreply.github.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: Needs approval from an approver in each of these files:Approvers can indicate their approval by writing |
There was a problem hiding this comment.
Read the hook and the tree at 3220360; the diff is consistent with the mechanism described, with one fact I could not verify from this repository.
Verified
system_files/shared/usr/share/ublue-os/user-setup.hooks.d/20-oem-brew.sh:32-34—set -xeuo pipefailprecedesbrew bundle, so a non-zero bundle exit aborts before the dconf logo write (line 42) and beforeversion-script-commit(line 49). The failure mode in the body matches the code.grep -rn 'framework[-_]tool'across the repo: the only three underscore occurrences are the three the diff rewrites; no other Brewfile or recipe references either spelling.tests/test_oem_brew.batsusesrun !, whichtests/test_brew_preinstall.bats:412already relies on, so the bats version CI installs (unit-tests.yml:38) supports it.ASUS/packages.Brewfilecontents match the new ASUS assertions exactly.
Open question for a maintainer — the whole fix turns on ublue-os/tap publishing the cask as framework-tool (hyphen). That tap is outside what I can read; please confirm with brew info ublue-os/tap/framework-tool before merging. If the token is wrong the hook fails identically to today, so the downside is bounded.
Minor (low) — tests/test_oem_brew.bats:208-210 comment says the failure "permanently skip[s]" the logo write. The hook's own comment at 20-oem-brew.sh:47-48 and your PR body both say the opposite: because version-script-commit never runs, the hook retries every login. Suggest "skipping ... on every login" so the test comment doesn't contradict the hook it guards.
I have not approved or changed anything.
Confidence: 3/5 (needs attention) — 1 medium finding; 1 perspective requires a human decision
— hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88
Danathar
left a comment
There was a problem hiding this comment.
Approving at 3220360. ublue-os/homebrew-tap has Casks/framework-tool.rb, which answers the open question. The new bats case is a real guard: a read-only helper saw it pass at this head and fail with the old Brewfile restored. Small nit: tests/test_oem_brew.bats:210-211 says "permanently skipping", but the hook retries on every login.
castrojo
left a comment
There was a problem hiding this comment.
The ublue-os/tap cask token is framework-tool; framework_tool made brew bundle exit non-zero under set -euo pipefail in 20-oem-brew.sh, skipping the logo write and version stamp. The Brewfile fix is correct, the doc references are updated to match, and the new bats checks pin both OEM Brewfiles to the published tokens. test/validate/builds green.
Summary for newcomers
On a fresh Bluefin install on Framework hardware, the OEM brew hook should pull in the Framework wallpapers and write a Framework logo into the top-left menu. After the 1e552aa refactor moved that work into the data-driven
20-oem-brew.sh, it stopped working for anyone on a Framework chassis:brew bundlefails on a typo in the OEM Brewfile, and the rest of the hook body (the logo write, the version stamp) never runs. This PR fixes the typo and adds bats coverage so a future edit to those OEM Brewfiles cannot regress the same way again.Problem
system_files/shared/usr/share/ublue-os/oem/Framework/packages.Brewfilelisted the Framework system tool ascask "ublue-os/tap/framework_tool"(underscore). The actual cask inublue-os/homebrew-tapisframework-tool(hyphen), sobrew bundleexits non-zero on every Framework chassis.20-oem-brew.shruns underset -euo pipefail. Whenbrew bundleexits non-zero, the hook aborts before the dconfcustom-command-listlogo write and beforeversion-script-commit "oem-Framework". The version-script-check gate added in #1196 means the hook retries on the next login, but every retry hits the same missing cask and never records a stamp, so the dconf logo and the wallpapers never land. Users who rebooted, retried, or re-ran the hook manually all saw the same blank OEM state. This is the regression from the old10-theming.shlayout that #1449 reports: the wallpapers are not installed and the custom menu does not show a Framework logo on a fresh install.Change
cask "ublue-os/tap/framework_tool"tocask "ublue-os/tap/framework-tool"in the Framework OEM Brewfile so the bundle resolves.docs/skills/oem-hardware-hooks/references/oem-brew.md(the OEM directories table) anddocs/skills/brew-lifecycle/references/placement-rules.md(the ublue-os/tap cask list).tests/test_oem_brew.batsthat pin the shipped Framework and ASUS OEM Brewfile cask tokens against the upstream tap, including a negative assertion that no underscore variant (framework_tool) appears in the Framework Brewfile.The
scripts/validate-brewfiles.shBrewfile validator only walkssystem_files/shared/usr/share/ublue-os/homebrew/, not theoem/tree, so a targeted test is the right place to lock the OEM tokens.Tests
tests/test_oem_brew.batsnow has 15 cases (up from 13). The two new cases assert the exact upstream cask tokens in the shipped Framework and ASUS OEM Brewfiles and reject the underscore variant that caused this regression. All 15 cases pass locally:The new Framework test fails against the pre-fix Brewfile (verified by hand against a fixture) and passes against the fixed Brewfile.
Verification
bats tests/test_oem_brew.batspasses (all 15 cases)framework_tooltoken, passes against the fixedframework-tooltokenshellcheckclean on the modified test fileCloses #1449.
— hive: backend=omp model=minimax-code/MiniMax-M3
🐝 Hive Agent:
contributor| SHA:3220360