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
Sometimes I have a hook env that's not working properly anymore for some reason and I don't want to clean the whole pre-commit cache. In that case, it would be handy to only clean cache for certain repos, e.g along these lines:
originally I didn't even want to implement pre-commit clean since it usually is hiding a bug somewhere else (and it trains users to run the wrong and slow things whenever something goes wrong -- "oh just make clean && make" etc.)
I'm not really sure I want to add more features to it since that would encourage its use, thoughts?
I was also wondering about that trade-off. However, it's a reality that there are bugs in every piece of software and people need to find a way to work around them until they get solved. So I think if we properly document that people should file issues if they run into problems and use that as a strategy of last resort, I am not afraid that it will be abused. If it will, it's the responsibiliy of the user I think.
Activity
[-]Support `repos` argument for `$ pre-commit clean`[/-][+]Support `repos` argument for `pre-commit clean`[/+]asottile commentedon Apr 12, 2022
I'm hesitant to add this option
originally I didn't even want to implement
pre-commit cleansince it usually is hiding a bug somewhere else (and it trains users to run the wrong and slow things whenever something goes wrong -- "oh justmake clean && make" etc.)I'm not really sure I want to add more features to it since that would encourage its use, thoughts?
lorenzwalthert commentedon May 18, 2022
I was also wondering about that trade-off. However, it's a reality that there are bugs in every piece of software and people need to find a way to work around them until they get solved. So I think if we properly document that people should file issues if they run into problems and use that as a strategy of last resort, I am not afraid that it will be abused. If it will, it's the responsibiliy of the user I think.
asottile commentedon Dec 27, 2022
closing since I'm not planning to implement this