Hi Folks,
I would like to pass a variable with a wild card in an argument. My script works if I don't use a wildcard but fails when I use . I want to use the script like:
scriptname -F <filename>
@ i = 0
while ($i <= ${#argv})
switch ($argv[$i])
case -F:
set j = `echo $i +1 |bc`
set file = `echo $argv[$j]`
endsw
@ i++
end
I want my $file = filename*, that is with wild card.
Thanks in advance.
You can try putting the variable in double-quotes " ", but CSH's quoting functionality is extremely perplexing. See csh programming considered harmful.