Email address obfuscation in effect -- please
click here to turn it off.
[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
On Thu, 1 Mar 2001, Rob Judd wrote:
> mv "$file" "`echo $file | awk -F: '{print $NF}'`"
That is such an elegant line. It is exactly what I tried in tcsh before I
resorted to setting a shell variable. The problem in tcsh was that the
$NF was being treated as a variable whenever that long-second-filename-
expression was enclosed in double quotes. I needed the double quotes to
deal with the spaces, but the double quotes messed up the $NF. I think
the error message said that the NF variable was not defined.
I guess that's one reason why some people would say that bash is better
than tcsh.
Mike
--
To manage your subscription, go to http://mlug.missouri.edu/members/edit.php
Archives are available at http://mlug.missouri.edu/list-archives/