Ratings and Reviews

  Analyzed 8 days ago based on code collected 8 days ago.
Community Rating
4.32768
   

Average Rating:   4.3/5.0
Number of Ratings:   176
Number of Reviews:   1

My Review of GNU findutils

You have not rated or reviewed this project. Click below to rate/review.  
0
 
New Review

Most Recent Reviews

denilsonsa says:
Avatar
 
Find and xargs  
4
   
written about 5 years ago

'find' is a great tool, really powerful and useful.

'xargs', however, looks like a promising tool but I rarely use it because it is cumbersome to use. Basically, since the default behavior reads items separated by whitespace, 'xargs' is very difficult to use with filenames that might contain spaces. I know there must be some set of parameters to fix this, but then its use becomes less straightforward. Even the manpage recognizes this: "Because Unix filenames can contain blanks and newlines, this default behaviour is often problematic"

For this reason, I've never used xargs in years.

If I need to run something for multiple files, I do this (in bash):

for a in * ; do something "$a" ; done

Which is easier to read and to write (although slightly verbose).

Another option is this:

some | commands | here | while read a ; do something "$a" ; done

Finally, I can also just use the -exec parameter from 'find'.

0 out of 1 users found the following review helpful.

Did this review help you?

 
 

Creative Commons License Copyright © 2013 Black Duck Software, Inc. and its contributors, Some Rights Reserved. Unless otherwise marked, this work is licensed under a Creative Commons Attribution 3.0 Unported License . Ohloh ® and the Ohloh logo are trademarks of Black Duck Software, Inc. in the United States and/or other jurisdictions. All other trademarks are the property of their respective holders.