[Development] clang-format

Thiago Macieira thiago.macieira at intel.com
Fri Jun 22 17:26:05 CEST 2018


On Friday, 22 June 2018 07:40:58 PDT Scott Bloom wrote:
> In a series of wrapper scripts, essentially, everything checked in was
> converted to the check in format.  However each developer had their own
> format .  And on checkout, the code would be compare to it.
> 
> On "Diff" analysis of two reversions, you had to see the diff based on the
> checked in format.
> 
> It really made things, that much simpler... and we never heard people bitch
> and moan about where the curley brackets belong

Git has such a functionality, it's called the clean/smudge filters. See man 
gitattributes for more information.

But that still means the code you see is subject to the smudge filter's whims. 
We've concluded that it doesn't always do the right thing.

And besides, there's something new that didn't exist in the old days: code 
reviews. Gerrit has no such functionality and in any case, reviewers need to 
agree between themselves on what they ar reviewing.

-- 
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center






More information about the Development mailing list