tCleaner output for prtup - scripts - various script and utils
 (HTM) git clone git://z3bra.org/scripts
 (DIR) Log
 (DIR) Files
 (DIR) Refs
       ---
 (DIR) commit 5889ad597935d81e786dc5cada5ed03f7aacbb7a
 (DIR) parent f4d2b3224aab4e789d54af866615bac38d23205a
 (HTM) Author: z3bra <willy@mailoo.org>
       Date:   Fri,  4 Jul 2014 23:28:25 +0200
       
       Cleaner output for prtup
       
       Diffstat:
         M prtup                               |       8 +++++++-
       
       1 file changed, 7 insertions(+), 1 deletion(-)
       ---
 (DIR) diff --git a/prtup b/prtup
       t@@ -45,7 +45,7 @@ update_pkgfile() {
            sed -i "s/^version=.*$/version=$version/" Pkgfile
        
            # update sversion if it exists
       -    if grep 'sversion' Pkgfile; then
       +    if grep -q 'sversion' Pkgfile; then
                sed -i "s/^sversion=.*$/sversion=$sversion/" Pkgfile
        
            # create it otherwise
       t@@ -65,6 +65,12 @@ main() {
        
            # update Pkgfile accordingly
            update_pkgfile
       +
       +    if [ ! "$1" = "-q" ]; then
       +        echo "port   : $name"
       +        echo "version: $version"
       +        echo "commit : $sversion"
       +    fi
        }
        
        main