News for hackers. Stuff that matters.
Re:Prek: A better, faster, drop-in pre-commit replacement, e... by JoshTriplett on Tuesday February 03, 2026 @12:32PM (#46874079)
I think there's value in git hooks, but pre-commit is the wrong hook. This belongs in a hook that runs on attempted push, not on commit.
Re:Prek: A better, faster, drop-in pre-commit replacement, e... by fortuitous-frog on Tuesday February 03, 2026 @12:38PM (#46874182)
Re:Prek: A better, faster, drop-in pre-commit replacement, e... by anttihaapala on Tuesday February 03, 2026 @01:12PM (#46874762)
formatting should definitely be in pre-commit though, otherwise you'll destroy diffs.
Re:Prek: A better, faster, drop-in pre-commit replacement, e... by esafak on Tuesday February 03, 2026 @12:36PM (#46874164)
Run the light ones on commit, the heavy ones on push.
Re:Prek: A better, faster, drop-in pre-commit replacement, e... by Marsymars on Tuesday February 03, 2026 @04:42PM (#46877723)
"pre-commit the tool" supports the pre-push hook (as well as the various other hooks).