misc/125057: xargs needs an option to use only newlines to delimit args

Dave Yost Dave at Yost.com
Fri Jun 27 21:10:02 UTC 2008


>Number:         125057
>Category:       misc
>Synopsis:       xargs needs an option to use only newlines to delimit args
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Fri Jun 27 21:10:02 UTC 2008
>Closed-Date:
>Last-Modified:
>Originator:     Dave Yost
>Release:        Mac OS X
>Organization:
>Environment:
Darwin ip2 9.3.0 Darwin Kernel Version 9.3.0: Fri May 23 00:49:16 PDT 2008; root:xnu-1228.5.18~1/RELEASE_I386 i386
>Description:
It is very common nowadays to have lots of filenames with spaces in them.
The current solution to this is cumbersome:

find . - type f | tr '\012' '\000' | xargs -0 ls -ltr

Much easier and nicer would be something like this:

find . - type f | xargs -l ls -ltr

where -l is an option that tells xargs to treat each line of input as an argument to be quoted.
>How-To-Repeat:

>Fix:


>Release-Note:
>Audit-Trail:
>Unformatted:


More information about the freebsd-bugs mailing list