tazwok rev 239
Improve function report: Better looks & possibility to get the content of only one of the lists (cooklist/commit/broken/blocked)
author | Antoine Bodin <gokhlayeh@slitaz.org> |
---|---|
date | Thu Feb 10 21:14:01 2011 +0100 (2011-02-10) |
parents | 107bcb7539a2 |
children | 38f279f7cd0a |
files | tazwok |
line diff
1.1 --- a/tazwok Thu Feb 10 17:53:16 2011 +0100 1.2 +++ b/tazwok Thu Feb 10 21:14:01 2011 +0100 1.3 @@ -2712,9 +2712,27 @@ 1.4 check_root 1.5 get_tazwok_config 1.6 cd $PACKAGES_REPOSITORY 1.7 - for i in commit cooklist incoming broken blocked; do 1.8 + if [ "$2" ]; then 1.9 + case $2 in 1.10 + commit|cooklist|incoming|broken|blocked) 1.11 + show="$2" 1.12 + ;; 1.13 + *) 1.14 + echo "usage : tazwok report [commit|cooklist|incoming|broken|blocked]" >&2 1.15 + exit 1 1.16 + ;; 1.17 + esac 1.18 + else 1.19 + show="commit cooklist incoming broken blocked" 1.20 + fi 1.21 + for i in $show; do 1.22 if [ -s $i ]; then 1.23 - echo -e "\n********************* $i *********************\n$(cat $i)\n*********************" 1.24 + echo "" 1.25 + echo -e "\033[1m$i\033[0m" 1.26 + echo "================================================================================" 1.27 + cat $i 1.28 + echo "================================================================================" 1.29 + echo "" 1.30 fi 1.31 done 1.32 ;;