[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: your mail




> b ()
> {
>         UP=".."
>         SUB="0"
>         until [ $SUB -gt "$1" ]; do
>                 BACK=$(( $BACK/$UP ))
>         done
>         cd $BACK
> }

First, make sure this function appears in the script BEFORE it's used, or
it'll fail.

Secondly, you aren't incrementing $SUB, so it'll never be greater than $1.

Thirdly, this:  BACK=$(( $BACK/$UP ))  is an arithematic expression. I
think you meant to say:  BACK=$BACK"/"$UP

Finally, does $BACK need an initial definition? Or does that happen
elsewhere?


-J

-
To unsubscribe, send email to majordomo@luci.org with
"unsubscribe luci-discuss" in the body.