On Wed, Oct 14, 2009 at 6:21 AM, Mike Frysinger <vap...@gentoo.org> wrote:
> On Wednesday 14 October 2009 05:08:08 Cappelletti Fabio wrote:
>> Hi all, I'm tying to  write a simple hush script , but I have a lot of
>> problem with two commands : expr and cat!
>> In particula my script is as follow:
>> #!/bin/hush
>> A= `cat /proc/driver/cardtype/BoardAddr`
>> B= `expr $A \* 2`
>> C= `expr $B -1`
>
> you know you cant go sticking whitespace wherever you like, right ?  shell
> scripts are not make files -- whitespace around the "=" matters.

+1

specifically, try removing the space after the "=" in all 3 lines:
A=`cat ...`
B=`expr ...`
C=`expr ...`

and there may also be a problem with the spaces
 in the "expr" lines.

You should be able to try each command on the command
 line, including the 'A=' part until you have the syntax correct,
 then the script should also work.

HTH,


-Bob
_______________________________________________
uClinux-dev mailing list
uClinux-dev@uclinux.org
http://mailman.uclinux.org/mailman/listinfo/uclinux-dev
This message was resent by uclinux-dev@uclinux.org
To unsubscribe see:
http://mailman.uclinux.org/mailman/options/uclinux-dev

Reply via email to