logoalt Hacker News

iamflimflam1yesterday at 9:25 PM1 replyview on HN

Rather than bake that into the prompt - wouldn’t it be better to just set up a pre commit hook that runs tests and linting?


Replies

mh-yesterday at 9:28 PM

Maybe, depends on their workflow. In my human workflow, I tend to use commits as checkpoints and then squash before pushing. I'd usually only run time-consuming tests before squash+push.

But yes, anything you want to ensure really needs to be a hook.

edit: realizing with "precommit" you probably meant a git hook not one in their harness. I'd have written the same response more or less though. :)

show 1 reply