summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2010-11-09 21:42:43 (GMT)
committerH. Peter Anvin <hpa@zytor.com>2010-11-09 21:42:43 (GMT)
commit2bf6f6f12cfb1b111b0a21163b52ad9869bf3411 (patch)
tree4d38508455264366ba01e447fa68c4f3e3056842
parent6afc81347378a208a99861329fc0bf3bd8827b3c (diff)
downloadtip-bot-2bf6f6f12cfb1b111b0a21163b52ad9869bf3411.zip
tip-bot-2bf6f6f12cfb1b111b0a21163b52ad9869bf3411.tar.gz
tip-bot-2bf6f6f12cfb1b111b0a21163b52ad9869bf3411.tar.bz2
tip-bot-2bf6f6f12cfb1b111b0a21163b52ad9869bf3411.tar.xz
Need wc -l < foo not wc -l foo to get only a numeric output
-rwxr-xr-xrobot.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/robot.sh b/robot.sh
index 893d60e..fc2d3c8 100755
--- a/robot.sh
+++ b/robot.sh
@@ -47,13 +47,13 @@ date=$(date -uR)
if [ x"$NEW_HEAD" != x"$OLD_HEAD" ]; then
git rev-list --reverse --no-merges ^linus/master ^$OLD_HEAD $NEW_HEAD > "$tmpdir"/revlist.$$
- if [ $(wc -l "$tmpdir"/revlist.$$) -gt 200 ]; then
+ if [ $(wc -l < "$tmpdir"/revlist.$$) -gt 200 ]; then
# Failsafe!
exit 1
fi
(
while read rev; do
- "$topdir"/robotfmt.pl $rev "$topdir"/branches
+ : "$topdir"/robotfmt.pl $rev "$topdir"/branches
done
) < "$tmpdir"/revlist.$$
rm -f "$tmpdir"/revlist.$$