Skip to content

Commit 034c3f0

Browse files
committedMay 28, 2018
Revert "Merge pull request #5461 from m-kuhn/less_temp_files"
This reverts commit cfad3aa, reversing changes made to cdca708.
1 parent 4c3a9ef commit 034c3f0

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed
 

‎scripts/astyle.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,6 @@ astyleit() {
8181
scripts/doxygen_space.pl "$modified"
8282
diff "$1" "$modified" >/dev/null || mv "$modified" "$1"
8383
rm -f "$modified"
84-
rm -f "$modified.sortinc"
8584
}
8685

8786
for f in "$@"; do

‎scripts/prepare-commit.sh

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -91,19 +91,22 @@ for f in $MODIFIED; do
9191

9292
cp $f $m
9393
ASTYLEPROGRESS=" [$i/$N]" astyle.sh $f
94-
diff -u $m $f >>$ASTYLEDIFF
95-
rm $m
94+
if diff -u $m $f >>$ASTYLEDIFF; then
95+
# no difference found
96+
rm $m
97+
fi
9698
done
9799

98100
if [ -s "$ASTYLEDIFF" ]; then
99101
if tty -s; then
100102
# review astyle changes
101103
colordiff <$ASTYLEDIFF | less -r
102104
else
103-
echo "Files changed"
105+
echo "Files changed (see $ASTYLEDIFF)"
104106
fi
107+
else
108+
rm $ASTYLEDIFF
105109
fi
106-
rm $ASTYLEDIFF
107110

108111

109112
# verify SIP files

0 commit comments

Comments
 (0)
Please sign in to comment.