shell scripting style question
bscott at ntisys.com
bscott at ntisys.com
Thu Dec 5 09:58:50 EST 2002
On Thu, 5 Dec 2002, at 7:36am, eprice at ptc.com wrote:
> Just out of curiosity, is the only difference between using "find" and "ls
> -R" (in this particular case) that you can use more than one glob
> argument?
The ls(1) command is oriented more towards human consumption. The find(1)
command simple outputs a list of filenames, which is more suitable for
consumption by other programs.
On occasion, I will use the output of find(1) to drive ls(1), when I want
to select certain files and then display them in a friendly format. For
example, something like this:
find -foo bar -baz fum -print0 | xargs -0 ls -hlrt
--
Ben Scott <bscott at ntisys.com>
| The opinions expressed in this message are those of the author and do not |
| necessarily represent the views or policy of any other person, entity or |
| organization. All information is provided without warranty of any kind. |
More information about the gnhlug-discuss
mailing list