Hacker News new | ask | show | jobs
by resters 775 days ago
Why not just set up a rule to auto-format the code before it is committed so that nobody wastes time discussing formatting trivialities and the repo stays consistent?
1 comments

It would be fantastic if there was a good normal-form formatter I could use for local work, and let automation format the code back to lint style. Unfortunately with something like IntelliJ/Java the commit-time reformat is not reversible. Maybe google's Java formatter is, hmm.
In JavaScript land, prettier auto-formatting the code on file save is quite lovely.

I would not be a fan of commit hook auto-formatting.