3 ms·
Sure, it's difficult for a committer to keep up with all of the different styles. Imagine being a developer on a project with 50 different committers, all doing
by dpcx 10y ago
Sure, it's difficult for a committer to keep up with all of the different styles. Imagine being a developer on a project with 50 different committers, all doing it their own way.
As a committer, I would rather have it clearly explained what the rules are before I do it incorrectly. Sure, having tools that will do it for me is awesome, but considering how many examples in the OP are different because of historical reasons, those tools are difficult to configure.
- danilocesar 10y ago> Sure, it's difficult for a committer to keep up with all of the different styles. Imagine being a developer on a project with 50 different committers, all doing it their own way. That's exactly what tools like clang-format fixes. Code will be in the repository using one correct styling. The difference is that the commiter won't have to style it himself. > As a committer, I would rather have it clearly explained what the rules are before I do it incorrectly. Sure, having tools that will do it for me is awesome, but considering how many examples in the OP are different because of historical reasons, those tools are difficult to configure. Which tools you said that are difficult to configure? clang-format? It's 5~20 lines in a .clang-format in the root folder of your repo. Configure it once and profit forever. * I'm talking about clang-format here because that's what I use for C/C++. I don't know anything about other languages.
- dpcx 10y agoHow well does clang-format handle subfolders with their own rules? I don't know, as I'm not a C/C++ developer; but I know that the tools I use don't handle them very well. I still provide them, of course, because it's better than nothing.