cookiecutter-adafruit-circuitpython icon indicating copy to clipboard operation
cookiecutter-adafruit-circuitpython copied to clipboard

Add --diff to black command

Open tannewt opened this issue 5 years ago • 5 comments

That way we can hand-fix small PRs that break formatting.

tannewt avatar Jul 13 '20 22:07 tannewt

@Flameeyes Do you know how we can do this now that we're using pre-commit?

evaherrada avatar Sep 10 '20 19:09 evaherrada

Good question — the hook documentation says not to use args, but that implies that args exists… so it would just be a matter of adding that to the hook.

But of course that would print the diff and fail on pre-commit instead of fixing it when running pre-commit locally.

Flameeyes avatar Sep 12 '20 12:09 Flameeyes

@tannewt Is this still something you'd like me to try to do given that it could cause issues when running locally

evaherrada avatar Oct 07 '20 19:10 evaherrada

Can we run it twice or call regular diff afterwards?

tannewt avatar Oct 08 '20 20:10 tannewt

@tannewt Yeah, I think that should work. I can try to take a look at doing this sometime soon.

evaherrada avatar Oct 16 '20 19:10 evaherrada