You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(hooks): pre-commit lints the whole ui submodule on a pointer bump, blocking every bump #470
The pre-commit hook lints the entirepackages/ui submodule whenever its pointer moves, and reports pre-existing violations as "Errors in staged files" — so it blocks the commit even when the change is only the 40-byte gitlink.
Reproduced on #444's pointer bump. 20 violations, none in any file the change touched:
As written, this blocks anypackages/ui pointer bump — so every such commit has to use --no-verify, which also skips the checks that would have been useful. Same applies to packages/sdk.
Fix options: treat a gitlink-only change as not implicating the submodule's contents; or scope the lint to files actually changed within the submodule; or gate on "no new violations vs. the merge base" rather than an absolute zero. Paying down the 20 existing violations would help but does not fix the mechanism.
Still live as of 2026-08-19, hit again on the prototype-parity pointer bump (#621, Scaffald/ui#18).
Same shape as reported, count now 19 at the new pointer — the extra platform/useHaptics.ts entry from the original list is gone, everything else is identical. None of the flagged files are touched by the bump; the diff is five token/component files plus the gitlink.
Both commits in that PR had to use --no-verify, which is the part that actually costs something: it skipped the formatting pass the hook would otherwise have run on the files I did change, so I had to run nx run-many -t lint by hand to get equivalent coverage. The rail is off for the whole commit, not just for the submodule.
Suggested narrowing, in case it helps whoever takes this: the hook only needs to lint paths inside the superproject diff. A staged gitlink (mode 160000) carries no lintable content — git diff --cached --diff-filter=d --name-only filtered against git ls-files -s | awk '$1 == "160000"' would drop submodule entries before the lint step, leaving the rest of the hook intact.
Activity
thinkclay commentedon Aug 19, 2026
Still live as of 2026-08-19, hit again on the prototype-parity pointer bump (#621, Scaffald/ui#18).
Same shape as reported, count now 19 at the new pointer — the extra
platform/useHaptics.tsentry from the original list is gone, everything else is identical. None of the flagged files are touched by the bump; the diff is five token/component files plus the gitlink.Both commits in that PR had to use
--no-verify, which is the part that actually costs something: it skipped the formatting pass the hook would otherwise have run on the files I did change, so I had to runnx run-many -t lintby hand to get equivalent coverage. The rail is off for the whole commit, not just for the submodule.Suggested narrowing, in case it helps whoever takes this: the hook only needs to lint paths inside the superproject diff. A staged gitlink (mode
160000) carries no lintable content —git diff --cached --diff-filter=d --name-onlyfiltered againstgit ls-files -s | awk '$1 == "160000"'would drop submodule entries before the lint step, leaving the rest of the hook intact.feat(mobile): the phone tab bar mirrors the role you are in (#639)