# HG changeset patch # User Christophe Lincoln # Date 1396197295 -7200 # Node ID b70363c4c5e2aacdfc5046c90b970047c43e2456 # Parent aded92d8f7bf86c8260e24e72c8fce9c3fd9986b spk-find: fix count diff -r aded92d8f7bf -r b70363c4c5e2 spk-find --- a/spk-find Sat Mar 29 11:04:11 2014 +0000 +++ b/spk-find Sun Mar 30 18:34:55 2014 +0200 @@ -40,6 +40,7 @@ newline boldify $(gettext "Spk find: $find") separator + IFS="|" grep "$find" $pkgsdesc | while read pkg vers desc null do @@ -47,7 +48,15 @@ echo -n "$pkg"; indent 16 "$desc" done unset IFS + +if [ -f "$count" ]; then + count=$(cat $count | wc -l) + color=32 +else + count=0 + color=31 +fi separator -boldify "Packages found: $(cat $count | wc -l)" && newline +boldify "Packages found: $(colorize $color $count)" && newline rm -rf $count exit 0