[
https://issues.apache.org/jira/browse/MESOS-1291?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14148806#comment-14148806
]
Michael Park commented on MESOS-1291:
-------------------------------------
I've decided to push ahead with {{clang-format-3.5}} as the standard tool
available in {{support}}.
The review request mentioned above is continued
[here|https://reviews.apache.org/r/26069].
If you don't know what ClangFormat is, check out this
[demo|http://www.youtube.com/watch?v=uvddFPavYZQ#t=23m28s].
If you're curious how close this {{.clang-format}} is to the [Mesos C++ Style
Guide|http://mesos.apache.org/documentation/latest/mesos-c++-style-guide/],
check out the *Example Diffs* section in the [Google
Doc|https://docs.google.com/document/d/13mC3CuG89x0-4mGUD1NK-M0mYsqvEcZ-ttx9CRmAXq8/edit?usp=sharing].
> Use clang-format to automatically format code to style
> ------------------------------------------------------
>
> Key: MESOS-1291
> URL: https://issues.apache.org/jira/browse/MESOS-1291
> Project: Mesos
> Issue Type: Improvement
> Components: technical debt
> Reporter: Dominic Hamon
> Labels: style
>
> Instead of relying on a script to check and report style errors, we should
> move to a workflow that allows people to write code how they feel comfortable
> and then automatically format it to conform to our style guide.
> The Chromium style from clang-format
> (http://clang.llvm.org/docs/ClangFormat.html) is very close to our style
> except for the dropped braces on class, struct, and function definitions, and
> two lines of whitespace between method definitions outside a class. As such,
> we should consider adopting clang-format and patching it to include a Mesos
> style variant.
> It can be run as part of post-reviews or as a git commit hook, or manually
> from within editors.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)