X-Git-Url: http://git.tuebingen.mpg.de/?a=blobdiff_plain;f=funcs%2Fgsu;h=4c9eb2dfca2adb897d4bd47f690df9c0884745c5;hb=725d6bd9c5c8c3670373496cb9c07cab86c3c4ff;hp=36b177afc74c9cc74de5b1860becb738f9f67a60;hpb=ad8528c2891cd97edb64e37de79cbff53f4a11df;p=gsu.git diff --git a/funcs/gsu b/funcs/gsu index 36b177a..4c9eb2d 100644 --- a/funcs/gsu +++ b/funcs/gsu @@ -17,7 +17,7 @@ $gsu_errors #echo "a:$a, b: $b" gsu_error_txt[i]="$b" eval $a=$i - i=$((i + 1)) + i=$(($i + 1)) done << EOF $gsu_errors EOF @@ -85,7 +85,7 @@ gsu_err_msg() else txt="${gsu_error_txt[$err]}" fi - echo "$gsu_self: $txt" 1>&2 + gsu_msg "$txt" } export -f gsu_err_msg @@ -118,11 +118,11 @@ com_help() | sed -e 's/^com_\([a-zA-Z_0-9]\+\)()#*/\1\t/' \ | sort \ | while read a b; do - echo -en "$a\t" - if test ${#a} -lt 8; then - echo -en "\t" - fi - echo "$b" + printf "$a\t" + if test ${#a} -lt 8; then + printf "\t" + fi + echo "$b" done echo gsu_msg "Try $gsu_self help for info on ." @@ -161,8 +161,8 @@ gsu_print_available_commands() gsu_short_msg "Available commands:" for i in $gsu_cmds; do printf "$i" - count=$((count + 1)) - if test $((count % 4)) -eq 0; then + count=$(($count + 1)) + if test $(($count % 4)) -eq 0; then echo else printf "\t"