Skip to content

ci: drop build + tests from the pre-push hook#88

Merged
ShortArrow merged 1 commit into
mainfrom
ci/slim-pre-push-hook
Jul 22, 2026
Merged

ci: drop build + tests from the pre-push hook#88
ShortArrow merged 1 commit into
mainfrom
ci/slim-pre-push-hook

Conversation

@ShortArrow

Copy link
Copy Markdown
Owner

Slims the local git hooks so build + tests are owned by CI, not the pre-push hook.

Why

Pre-push ran dotnet build + dotnet test --filter "Category!=Integration" on every non-docs push. That:

  • duplicated the PR CI gate (pr.yml already builds/tests) while diverging from it — the local run has no --locked-mode and a different SDK/OS, so a local pass didn't imply a CI pass and a local failure was sometimes environmental;
  • added minutes of latency to every push, and — bypassable with --no-verify — was never a hard gate;
  • had grown a ~30-line docs-only skip script that re-implemented CI's changed-files logic locally (a second copy that can drift), just to stay usable;
  • was wasteful even on tag pushes (nothing to validate on an already-merged, already-CI'd commit).

What

  • Remove .husky/pre-push and its build / test task group from .husky/task-runner.json. The docs-only skip script goes with it.
  • Kept: the fast pre-commit CSharpier format check.
  • CI (pr.yml) remains the authoritative build/test gate.
  • Docs updated: ADR 0025 (§4 supersedes the old pre-push decision, §8, §10), README, and CONTRIBUTING — EN + JP in lockstep.

No product code changes.

Pre-push ran `dotnet build` + `dotnet test`, duplicating the PR CI gate while
diverging from it (no --locked-mode, different SDK/OS), adding minutes to every
non-docs push, and — bypassable with --no-verify — never being a hard gate. It
had also grown a docs-only skip script that re-implemented CI's changed-files
logic locally. Remove the pre-push hook and its build/test task group; CI
(`pr.yml`) remains the authoritative build/test gate. The fast pre-commit
CSharpier check stays. ADR 0025, README, and CONTRIBUTING updated (EN + JP).
@ShortArrow
ShortArrow merged commit 34259b0 into main Jul 22, 2026
6 checks passed
@ShortArrow
ShortArrow deleted the ci/slim-pre-push-hook branch July 22, 2026 05:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant