On Sat, 2005-01-15 at 08:10, Matt Wilson wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > daniel wrote: > | On January 14, 2005 01:19 pm, Boyd Stephen Smith Jr. wrote: > | > |>On Friday 14 January 2005 07:00 am, Ow Mun Heng <[EMAIL PROTECTED]> > | you could probably use: > | > | $ find . -type f -maxdepth 1 -name '*gentoo*' -print0 | \ > | xargs -0 --replace mv "{}" /path/to/new/dir/ > > I'm always a little confused as to why people always jump to suggest the > use of xargs when find's -exec works perfectly well; > > $ find . -type f -maxdepth 1 -name "*gentoo*" -exec mv "{}" > /path/to/new/dir/ \; > > Is there any particular reason why people would recommend using xargs > over -exec? >
I may not be correct, but reading through xargs and some other docs, suggest that there is a _limit_ on the # of arguments accepted on the CLI before it gets "too many arguments" Xargs can cut and paste the long list into a few bundles for execution. Slide and Dice. -- Ow Mun Heng Gentoo/Linux on DELL D600 1.4Ghz 98% Microsoft(tm) Free!! Neuromancer 15:26:03 up 5:28, 5 users, load average: 0.47, 0.33, 0.27 -- gentoo-user@gentoo.org mailing list