{"action":"closed","issue":{"url":"https://api.github.com/repos/arduino/ArduinoCore-avr/issues/71","repository_url":"https://api.github.com/repos/arduino/ArduinoCore-avr","labels_url":"https://api.github.com/repos/arduino/ArduinoCore-avr/issues/71/labels{/name}","comments_url":"https://api.github.com/repos/arduino/ArduinoCore-avr/issues/71/comments","events_url":"https://api.github.com/repos/arduino/ArduinoCore-avr/issues/71/events","html_url":"https://github.com/arduino/ArduinoCore-avr/issues/71","id":406947012,"node_id":"MDU6SXNzdWU0MDY5NDcwMTI=","number":71,"title":"Using Clang-Format for Automatic Source Code Formatting","user":{"login":"pratikpc","id":28534575,"node_id":"MDQ6VXNlcjI4NTM0NTc1","avatar_url":"https://avatars2.githubusercontent.com/u/28534575?v=4","gravatar_id":"","url":"https://api.github.com/users/pratikpc","html_url":"https://github.com/pratikpc","followers_url":"https://api.github.com/users/pratikpc/followers","following_url":"https://api.github.com/users/pratikpc/following{/other_user}","gists_url":"https://api.github.com/users/pratikpc/gists{/gist_id}","starred_url":"https://api.github.com/users/pratikpc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pratikpc/subscriptions","organizations_url":"https://api.github.com/users/pratikpc/orgs","repos_url":"https://api.github.com/users/pratikpc/repos","events_url":"https://api.github.com/users/pratikpc/events{/privacy}","received_events_url":"https://api.github.com/users/pratikpc/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2019-02-05T19:50:36Z","updated_at":"2019-09-17T12:45:46Z","closed_at":"2019-09-17T12:45:46Z","author_association":"NONE","body":"In many portions of the Library we find that an inconsistent C++ Code formatting style is followed.\r\nFor example, certain places have\r\n1. Different Tab Sizes\r\n2. Different Brace Styles(Allman vs 1TBS/K&R/Stroustrup)\r\n\r\nWe could use an Automatic Source Formatter to rectify such issues.\r\nWhile I would recommend Clang-Format, [AStyle](http://astyle.sourceforge.net/) also exists\r\n\r\nWe could create a configuration file and define the properties.\r\nFor a sample Clang-Format configuration, [see this](https://clang.llvm.org/docs/ClangFormatStyleOptions.html)\r\nWe could decide on what the properties would be here.\r\n\r\nTo simplify our tasks and reduce the conflicts that come with the question, Clang-Format also provides a few default styles like:-\r\n1. LLVM\r\n2. Google\r\n3. Chromium\r\n4. Mozilla\r\n5. WebKit"}}
{"actor":{"display_login":"lxrobotics"}}