On Wed, Dec 07, 2005 at 06:20:39AM -0700, Eric Blake wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > According to James Youngman on 12/7/2005 1:43 AM: > > > > This means that I'm considering changing the output quoting method for > > -ls and -print where the output goes to a tty. Should I also consider > > changing -ls and -fls to just print the literal pathname if the output > > is going to a non-terminal? > > I would argue for adding a --quoting-style option (or > -quoting-style) to match ls, and allow the user to choose which > output quoting style find uses, regardless of whether stdout is a > tty or not. When that flag is not present, I would make all > filenames printed to a tty be quoted on the grounds that it is for > human consumption, and all filenames printed to a non-terminal be > literal on the grounds that the tool you are piping to should not > have to unquote the name.
Looking at coreutils' ls.c, I notice that the substitution of ? for "funny" characters and the quoting style are orthogonal, because the quoting style will not (always) prevent control characters being sent to the terminal. Thus the control of the quoting style and the control of ?-substitution are separate. It might make sense to do something similar in findutils, but perhaps that's an unneccesary complexity. James. _______________________________________________ Bug-findutils mailing list [email protected] http://lists.gnu.org/mailman/listinfo/bug-findutils
