From 8bfaa5ffc3fa2194a1a42d233185892aee7164aa Mon Sep 17 00:00:00 2001 From: Max Brunsfeld Date: Mon, 11 Apr 2016 23:11:37 -0700 Subject: [PATCH] Add directory argument to format script --- script/format | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/script/format b/script/format index f92522bd..1aa8fbee 100755 --- a/script/format +++ b/script/format @@ -1,6 +1,7 @@ #!/usr/bin/env bash -find \ - src include \ +DIRS="${*:-src include}" + +find $DIRS \ -name '*.c' -or -name '*.cc' -or -name '*.h' | \ xargs clang-format -i -style=file