diff options
Diffstat (limited to '')
-rwxr-xr-x | indent.sh | 9 |
1 files changed, 8 insertions, 1 deletions
@@ -4,5 +4,12 @@ # -l120 Set maximum line length for non-comment lines to 150. # -pmt Preserve access and modification times on output files. -indent -kr -l120 -pmt *.c *.h +indent -kr -l120 *.c *.h +for i in *.c *.h; do + if !(diff -q $i $i~); then + rm $i~ + else + mv $i~ $i + fi +done |