Daniel D Jones <[email protected]> wrote:
> Running the command:
>
> find -name *.ext | xargs -0 rm
>
> I get the result:
>
> rm: cannot remove `Long File Name One.ext\nLong File Name Two.ext\nLong File
> Name Three.ext\n': File name too long.
>
> (The actual list is much longer than this, of course, or I wouldn't be using
> xargs.) For some reason, the \n isn't being recognized as a separator but
> rather as a part of a single long file name. Don't think $IFS would affect a
> command like rm but it doesn't appear to be the issue:
>
> ddjo...@merlin ~ $ set | grep IFS
> IFS=$' \t\n'
>
> I don't see any other ser variable which looks like a likely candidate to
> cause the behavior. Anyone have a clue what's going on?
Why do you have -0 -- this replaces the \n's with a null character -- is
that what you want?
--
Your life is like a penny. You're going to lose it. The question is:
How do
you spend it?
John Covici
[email protected]