From b65291579fc71a03469252cb27a3e78809eb54a5 Mon Sep 17 00:00:00 2001 From: Daniel Agar Date: Tue, 21 Jun 2016 11:49:42 -0400 Subject: [PATCH] show bad formatting diff --- Tools/check_code_style.sh | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Tools/check_code_style.sh b/Tools/check_code_style.sh index ab012b1c09..5ffc0ac5d2 100755 --- a/Tools/check_code_style.sh +++ b/Tools/check_code_style.sh @@ -9,6 +9,13 @@ then ${DIR}/fix_code_style.sh --dry-run $file | grep --quiet Formatted if [[ $? -eq 0 ]] then + ${DIR}/fix_code_style.sh --quiet < $file > $file.pretty + + echo + git diff --no-index --minimal --histogram --color=always $file $file.pretty + echo + + rm -f $file.pretty echo $file 'bad formatting, please run "./Tools/fix_code_style.sh' $file'"' exit 1 fi