>I have a pictures directory. in that directory are
>three more called disk1, disk2, and disk3.
>
>What the script is *supposed* to do is "ls $1*.jpg"
>but when I use disk* as the variable, all I get back
>is the contents of disk1.
Let's say that you've named your script tomScript.
>From your description it sounds like you're invoking
it thus:
tomScript disk*
and then expecting to see the string "disk*" as the
first argument. But recall that the shell will first
expand disk* to
disk1 disk2 disk3
before launching your script and passing that
expanded list as its aruments, so your script
will see its $1 as disk1, just as you report.
You can illustrate this for yourself (for
debugging purposes) by putting a line like
this somewhere in your script:
echo Args are: $*
For quick and dirty scripts it's probably more
trouble than it's worth to try to make them
able to accept and then expand filename RE's
(Regular Expressions, ie wildcards) specified
on the command line - much simpler for them
to expect verbatim lists of files as arguments,
with the (invoking) shell having already done
all that dirty work...
**********************************************************
To unsubscribe from this list, send mail to
[EMAIL PROTECTED] with the following text in the
*body* (*not* the subject line) of the letter:
unsubscribe gnhlug
**********************************************************