]> git.tuebingen.mpg.de Git - gsu.git/commitdiff
gsu: Fix two bashisms.
authorAndre Noll <maan@oka.kyb.local>
Thu, 26 Jul 2007 13:40:42 +0000 (15:40 +0200)
committerAndre Noll <maan@tuebingen.mpg.de>
Fri, 29 Aug 2014 19:36:07 +0000 (21:36 +0200)
Always include the '$', even in math expressions where bash doesn't
need it.

funcs/gsu

index 221aad6c332ff4c370cd0c1500f3c44503af990e..106663af381b04b6f2650856952c986592f4f9d5 100644 (file)
--- 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
@@ -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"