GitHub - thebigG/clang_format_all: Use clang-format the easy way. Python fork of https://github.com/eklitzke/clang-format-all

1 min read Original article ↗

This is a python script that will run clang-format -i on your code.

clang_format_all --config config.yaml
root_dir: "."

#When true, files will only be checked. None will be modified.
check_all: true

file_extensions: ['.cpp', '.cc', '.C', 'CPP', '.c++', 'cp', '.cxx', '.h', '.hh', '.hpp']

exclude_dirs:
  - "fmt"
  - "simple_gpio"   
  - "build"

This tool uses clang-format. For supported languages/options supported in clang-format look here