your example only has 10 lines
verify that the script that produced error lines 15 & 17
is the same as the example script -- if not then post the real script

also, [ mv $FILE junkf ] is probably not what is intended, drop the [ ... ]
also too, the last line in ksh:

        [[ -s $FILE ]] && (( $(wc -l < $FILE) > 2 )) && mv $FILE /tmp/junkf

On Wed, 30 Jan 2008 09:43:47 -0500 Nemeth, Michael Kenneth (Mike) wrote:
> > I have the following test script (see below).  The last line commented
> > runs fine on ksh88 (solaris) and pdksh (rehat linux). When trying to
> > run the script on Version M 1993-12-28 s+ redhat linux I get  line 15:
> > syntax error at line 17: `&&' unexpected.  Could this be a bug?
> >=20
> >=20
> > #!/bin/ksh
> > ENV_DEBUGON=3DYES
> > [ "$ENV_DEBUGON" =3D=3D "YES" ] && set -x
> >=20
> > cat<<%END%>/tmp/junk
> > abc
> > %END%
> >=20
> > FILE=3D/tmp/junk
> > [ -s $FILE ] && [ `wc -l $FILE | nawk '{print $1}'` -gt 2 ] && [ mv
> > $FILE /tmp/junkf ]
> > #[ -s $FILE ] && (( `wc -l $FILE | nawk '{print $1}'` > 2 )) && [ mv
> > $FILE /tmp/junkf ]

_______________________________________________
ast-users mailing list
[email protected]
https://mailman.research.att.com/mailman/listinfo/ast-users

Reply via email to