Adopt .clang-format?

Daan De Meyer daan.j.demeyer at gmail.com
Sat Aug 17 23:19:56 BST 2019


Merge request with an initial take on a .clang-format configuration:
https://invent.kde.org/kde/kate/merge_requests/7

Regards,

Daan

On Sat, 17 Aug 2019 at 23:42, Dominik Haumann <dhaumann at kde.org> wrote:
>
> +1.
>
> I have a .clang-format already locally here, but right now have only my mobile phone.
>
> Please make a review request.
>
> Thanks
> Dominik
>
> Daan De Meyer <daan.j.demeyer at gmail.com> schrieb am Sa., 17. Aug. 2019, 23:38:
>>
>> Hi,
>>
>> Inclusion of a .clang-format file in the Kate repository would enable
>> more consistent formatting of Kate's source code. Is this something
>> that would be considered? I'm not particularly interested in
>> bikeshedding what style should be used, I mostly want to be able to
>> press a formatting shortcut and not have to worry about formatting
>> code review comments when I make a merge request. It should also mesh
>> nicely with the added LSP support as clangd should automatically pick
>> up a project's .clang-format file and apply its settings when
>> reformatting (although I'm not sure if Kate already supports
>> formatting via the LSP client).
>>
>> Should we adopt a .clang-format file, we would have to consider
>> whether reformatting would be done gradually or all in one go (which
>> has the annoying side effect of making it a lot harder to use git
>> blame). There's also the question of whether correct formatting would
>> be enforced (although setting this up might be more trouble than its
>> worth).
>>
>> Any thoughts?
>>
>> Regards,
>>
>> Daan


More information about the KWrite-Devel mailing list