hooks/pre-push runs, in Docker, before git transfers anything:
docker compose run debian cargo fmt --all --check
docker compose run debian cargo clippy --workspace --all-targets -- -D warnings
docker compose run debian cargo test --workspace
docker compose run alpine cargo test --workspace
docker compose run fedora cargo test --workspace
That is several minutes on every push, including pushes that transfer almost nothing — pushing the 0.2.2 tag moved one object and still blocked for over two minutes.
The predictable result is that it gets bypassed. Every push in the recent batch of work used --no-verify, because the same checks had just been run manually. A hook that is always skipped provides no protection while still costing time whenever someone forgets to skip it.
Options, roughly in order of preference:
- Scope it to what a push can actually break and what CI does not already cover — CI runs fmt/clippy/test on every PR, so the hook duplicates it.
- Skip entirely for pushes that carry no commits (tags, branch deletions).
- Run one distro locally and leave the matrix to CI, which has retries and runs the three distros in parallel.
- Drop it and rely on CI, which is the actual gate.
Worth deciding rather than leaving a hook everyone routes around.
hooks/pre-pushruns, in Docker, before git transfers anything:That is several minutes on every push, including pushes that transfer almost nothing — pushing the
0.2.2tag moved one object and still blocked for over two minutes.The predictable result is that it gets bypassed. Every push in the recent batch of work used
--no-verify, because the same checks had just been run manually. A hook that is always skipped provides no protection while still costing time whenever someone forgets to skip it.Options, roughly in order of preference:
Worth deciding rather than leaving a hook everyone routes around.