Skip to content

Instantly share code, notes, and snippets.

@JJL772
Last active August 9, 2020 01:12
Show Gist options
  • Save JJL772/117dab10ee161ed575ac1e8119ffd8b8 to your computer and use it in GitHub Desktop.
Save JJL772/117dab10ee161ed575ac1e8119ffd8b8 to your computer and use it in GitHub Desktop.
clang formatting script
#!/bin/bash
TOP=$(cd `dirname $0`;cd ..;pwd)
SRCDIR="$TOP/src/"
files=`find "$TOP" -iname "*.c" -o -iname "*.cpp" -o -iname "*.cc" -o -iname "*.h"`
for file in $files; do
clang-format -i $file
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment