clang-format is available as a plugin for Visual Studio 2010 and later from the bottom of this page. Just download and install, mark the source code to be formatted (Ctrl-A) and either select TOOLS|ClangFormat from the menu or simply press Ctrl-R Ctrl-F. This formats the selected code using the standard configuration. It also inserts and removes line breaks as seen fit.
There are multiple options how to give a different configuration to clang-format. Select TOOLS|Options from the menu and have a look:
Comment if you like this or have a better tool at hand!
No comments:
Post a Comment