An open API service indexing awesome lists of open source software.

https://github.com/povilasb/clang-format-sample

Basic sample of clang-format use.
https://github.com/povilasb/clang-format-sample

Last synced: 3 months ago
JSON representation

Basic sample of clang-format use.

Awesome Lists containing this project

README

        

=====
About
=====

This is a basic sample of clang-format use. This tool reformats C++ (and
other languages) code to match your defined style.

Installation
============

On debian wheezy latest available version is 3.5:

$ sudo apt-get install clang-format-3.5

Put `.clang-format` into your project root directory.

Vim integration
===============

Put this into `~/.vimrc`::

map :pyf /usr/share/vim/addons/syntax/clang-format-3.5.py
imap :pyf /usr/share/vim/addons/syntax/clang-format-3.5.py

`Ctrl + k` reformats current line or selected region (`shift + v`).