OSSP CVS Repository

ossp - Difference in ossp-pkg/shtool/sh.common versions 1.22 and 1.23
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [History

ossp-pkg/shtool/sh.common 1.22 -> 1.23

--- sh.common    2003/12/13 21:23:55     1.22
+++ sh.common    2004/04/07 07:55:02     1.23
@@ -47,7 +47,7 @@
 
 #   parse option alias string
 eval `echo h:help,$opt_alias |\
-      tr 'x-' 'x_' | sed -e 's/\([a-zA-Z0-9]\):\([^,]*\),*/opt_ALIAS_\2=\1;/g'`
+      sed -e 's/-/_/g' -e 's/\([a-zA-Z0-9]\):\([^,]*\),*/opt_ALIAS_\2=\1;/g'`
 
 #   interate over argument line
 opt_PREV=''
@@ -72,12 +72,12 @@
             --[a-zA-Z0-9]*=*)
                 eval `echo "x$1" |\
                       sed -e 's/^x--\([a-zA-Z0-9-]*\)=\(.*\)$/opt_OPT="\1";opt_ARG="\2"/'`
-                opt_STR=`echo $opt_OPT | tr 'x-' 'x_'`
+                opt_STR=`echo $opt_OPT | sed -e 's/-/_/g'`
                 eval "opt_OPT=\${opt_ALIAS_${opt_STR}-${opt_OPT}}"
                 ;;
             --[a-zA-Z0-9]*)
                 opt_OPT=`echo "x$1" | cut -c4-`
-                opt_STR=`echo $opt_OPT | tr 'x-' 'x_'`
+                opt_STR=`echo $opt_OPT | sed -e 's/-/_/g'`
                 eval "opt_OPT=\${opt_ALIAS_${opt_STR}-${opt_OPT}}"
                 opt_ARG=''
                 ;;

CVSTrac 2.0.1