'find' - can i prune on the basis of pathnames?

William E. Davidsen Jr davidsen at steinmetz.ge.com
Wed May 11 05:10:18 AEST 1988


Considering your application, you can get there from here by
  find . -name foo -print | egrep -v '\./name1|\./name1/" > file

The problem is that -prune only looks at the current filename
(basename). Therefore the name xxx is omitted from the output, but names
of the format xxx/anything will not be. I do much the same thing, and
drop anything with the string "/tmp/" in the name.
-- 
	bill davidsen		(wedu at ge-crd.arpa)
  {uunet | philabs | seismo}!steinmetz!crdos1!davidsen
"Stupidity, like virtue, is its own reward" -me



More information about the Comp.unix.questions mailing list