]> rtime.felk.cvut.cz Git - orte.git/commitdiff
Update uncrustify script to be usable in git-filter-branch
authorMichal Sojka <sojkam1@fel.cvut.cz>
Sat, 14 Mar 2015 13:15:37 +0000 (14:15 +0100)
committerMichal Sojka <sojkam1@fel.cvut.cz>
Sat, 14 Mar 2015 13:15:37 +0000 (14:15 +0100)
Now, it is possible to use 'git filter-branch --tree-filter orte/uncrustify'.

orte/uncrustify

index e4a30fd7ca8fa1ed06b664b11066915d7c7e496e..a15cb36d74b35761fcd690e5c7cddde32c1274ad 100755 (executable)
@@ -12,5 +12,5 @@ UNCRUSTIFY_CFG=${UNCRUSTIFY_CFG:-$0.cfg}
 
 git ls-files|git check-attr --stdin uncrustify|awk -F: '/uncrustify: set$/ {print $1}'|\
     while read file; do
-       git show HEAD:$file | (set -x; uncrustify -c $UNCRUSTIFY_CFG -o $file)
+       git show :$file | (set -x; uncrustify -c $UNCRUSTIFY_CFG -o $file)
     done