Updated script per suggestion by @g-oikonomou to allow script to operate on files in subdirectories

This commit is contained in:
Adam Dunkels 2012-11-20 20:11:01 +01:00
parent 9131c4183b
commit f6f9df802c
1 changed files with 4 additions and 3 deletions

View File

@ -1,8 +1,9 @@
#!/bin/sh
f=`basename $1`
mkdir /tmp/$$
cp $1 /tmp/$$/
cp $1 /tmp/$$/$1.orig
cp $1 /tmp/$$/$f.orig
export INDENT_PROFILE=`dirname $0`/indent.pro
indent /tmp/$$/$1
diff /tmp/$$/$1.orig /tmp/$$/$1
indent /tmp/$$/$f
diff /tmp/$$/$f.orig /tmp/$$/$f
rm -rf /tmp/$$