Author: gotar                        Date: Sun Feb 15 13:07:34 2009 GMT
Module: SOURCES                       Tag: HEAD
---- Log message:
- print help screen when no action specified,
- added -d alias to --delete,
- fix en language and typos.

---- Files affected:
SOURCES:
   banner.sh (1.7 -> 1.8) 

---- Diffs:

================================================================
Index: SOURCES/banner.sh
diff -u SOURCES/banner.sh:1.7 SOURCES/banner.sh:1.8
--- SOURCES/banner.sh:1.7       Sun Feb 15 13:53:10 2009
+++ SOURCES/banner.sh   Sun Feb 15 14:07:28 2009
@@ -1,6 +1,6 @@
 #!/bin/sh
 #
-# bug reports send to [email protected] or pld-devel-* lists
+# Please send bug reports to [email protected] or pld-devel-* lists
 #
 # 2004, GPL 2+
 #
@@ -10,7 +10,7 @@
 
 ####################################################### CONFIG ########
 
-# default paramaters
+# default parameters
 ##########################
 
 BANNERDIR="/var/lib/banner/"
@@ -19,7 +19,7 @@
 STDOUT="1"  # stdout by default
 #STDOUT="2" # stderr by default
 
-# config paramaeters
+# config parameters
 ##########################
 
 if [ -r $CONFIG ]; then
@@ -53,7 +53,7 @@
 Usage()
 {
        cat << EOF
-Usage: $(basename $0) [opitions] [banners]
+Usage: $(basename $0) [options] [banners]
 EOF
 }
 Help()
@@ -62,7 +62,7 @@
        cat << EOF
 -a
 --all       - all banners
---delete    - delete wanted banners
+-d, --delete    - delete specified banners
 -e
 --exclude   - exclude following banners (useful with -a)
 -h
@@ -77,14 +77,14 @@
 --newer     - all choosen banners should be newer than following parameter in 
seconds
 --older     - all choosen banners should be older than following parameter in 
seconds
 -s
---show      - show wanted banners
+--show      - show specified banners
 --stderr    - send banner to stderr instead of stdout (or other)
 --stdout    - send banner to stdout instead of stderr (or other)
 -u
 --usage     - show short help
 
-[1] - if there will be no slash ('/') in name then config dir will be used,
-      else -- specified.
+[1] if there is no slash ('/') in the given name default dir ($BANNERDIR) is 
used,
+    otherwise the one that's specified
 EOF
 }
 Unknown_para()
@@ -171,7 +171,7 @@
                -a|--all)
                        ALL_BANNERS=1
                        ;;
-               --delete)
+               -d|--delete)
                        NEED_BANNER_LIST=1
                        ACTION="delete"
                        ;;
@@ -278,6 +278,9 @@
                ;;
        "show")
                show_banners $BANNER_LIST;
+               ;;
+       "")
+               Help
                ;;
 esac
 
================================================================

---- CVS-web:
    
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SOURCES/banner.sh?r1=1.7&r2=1.8&f=u

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to