Closed williamjamir closed 2 years ago
I would be interested in this too. That said, pre-commit also fails whenever a hook changes a file so it might be possible to achieve with an appropriate .pre-commit-hooks.yaml
and no code changes.
I'd love this too - I came up with a workaround but it would be great if this was an available feature: https://til.simonwillison.net/python/cog-to-update-help-in-readme
This is implemented in commit a69b014, available as cog 3.3.0.
Is it possible to run cog to check if a file will be changed? If not, would it be possible to add a
--check
flag that returns a non-zero status code for CI and pre-commit purposes?