Sometimes there are situational choices that autoformatters cannot comprehend. I also failed to make formatters follow the style choices I use, they were just not configurable enough.
> Sometimes there are situational choices that autoformatters cannot comprehend.
I haven't stumbled across that. Could you give an example?
> I also failed to make formatters follow the style choices I use, they were just not configurable enough.
That's kind of the whole point. I love, love, love Python's Black formatter. In my opinion, it chose the wrong default for quoting strings (i.e. it re-writes single quotes as double quotes), which irked me until I gave up and accepted it. In return, I no longer have to put up with my coworkers' insane style choices, just as they no longer have to tolerate mine. With a single addition to our CI pipeline, the days of dumb arguments about the "right" way to format our code came to an end.
Some people also said "just accept it" and that's part of why I ditched it. If it can be helped I do not accept it. This is not limited to code formatters, I want to have control over the things I personally use. I want to be comfortable doing my stuff.
You've gotta choose your battles. In all the ways I might want to express myself with a computer, the exact formatting of my code is almost never one of them.
In our code base every “fmt: off” is compensating for a lack of scopes, smaller functions, variables, etc. Instead of cutting down on repetition we have dozens of consecutive lines of repetition. But nicely formatted repetition. Until that inevitable day where you have to change something, and everything breaks because you’re only supposed to change 90 of the 100 almost identical lines.
I haven't stumbled across that. Could you give an example?
> I also failed to make formatters follow the style choices I use, they were just not configurable enough.
That's kind of the whole point. I love, love, love Python's Black formatter. In my opinion, it chose the wrong default for quoting strings (i.e. it re-writes single quotes as double quotes), which irked me until I gave up and accepted it. In return, I no longer have to put up with my coworkers' insane style choices, just as they no longer have to tolerate mine. With a single addition to our CI pipeline, the days of dumb arguments about the "right" way to format our code came to an end.