aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorColin Okay <colin@cicadas.surf>2022-08-15 16:10:52 -0500
committerColin Okay <colin@cicadas.surf>2022-08-15 16:10:52 -0500
commit6ab7550762e5e2e697ca2accf47f505973a9c51e (patch)
tree5063bd71ed9280e33f95a77181f49c5f35e919b8
parent391acc08c3131cc1f192c4978f7b9ae5bf3e2806 (diff)
[modify] filter out blank lines in thread listing
-rwxr-xr-xthreadcat-list.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/threadcat-list.sh b/threadcat-list.sh
index ad2b21c..0be8ca8 100755
--- a/threadcat-list.sh
+++ b/threadcat-list.sh
@@ -12,9 +12,9 @@ if [ -z "${BOARD}" ]; then
echo ""
echo "TOP LEVEL THREADS"
echo $LISTING_HEADING
- ssh $THREADCAT_USER "ls -lt /opt/threadcat | grep -v ^d" | awk '{ s = ""; for (i = 6; i <= 9; i++) s = s $i " "; print s }'
+ ssh $THREADCAT_USER "ls -lt /opt/threadcat | grep -v ^d" | awk '{ s = ""; for (i = 6; i <= 9; i++) s = s $i " "; print s }' | grep -v '^ *$'
else
echo "Listing threads under $BOARD"
echo $LISTING_HEADING
- ssh $THREADCAT_USER "ls -lt /opt/threadcat/$BOARD | grep -v ^d" | awk '{ s = ""; for (i = 6; i <= 9; i++) s = s $i " "; print s }'
+ ssh $THREADCAT_USER "ls -lt /opt/threadcat/$BOARD | grep -v ^d" | awk '{ s = ""; for (i = 6; i <= 9; i++) s = s $i " "; print s }' | grep -v '^ *$'
fi