On Sun, 14 Nov 2010 22:01:09 -0500, Jameson Rollins <[email protected]> wrote: > On Fri, 12 Nov 2010 16:52:51 -0800, Carl Worth <[email protected]> wrote: > > This one is a simple one-liner as of notmuch 0.4: > > > > notmuch search --output=files tag:deleted -print0 | xargs -0 rm > > Is -print0 actually a command that notmuch accepts? It's not documented > as far as I can tell. And it doesn't seem to affect the output of the > command, i.e. whether or not it's used the output is still newline > delimited. I'm not seeing it in the source either.
No, it's not something implemented. I'm surprised I spouted such
nonsense above. I think what happened is that I first typed a command
line which would actually work, (for filenames without embedded newline
characters):
notmuch search --output=files tag:deleted | xargs rm
And then a habit kicked in from typing many find/xargs commands and I
retrofitted the command with -print0 and -0 as I originally sent it out.
Should we perhaps add a -0 option so that one could actually reliably
handle filenames with newlines in a case like this? Or can we just
assert that such filenames are insane and *should* cause problems?
-Carl
--
[email protected]
pgpGARpykLAsP.pgp
Description: PGP signature
_______________________________________________ notmuch mailing list [email protected] http://notmuchmail.org/mailman/listinfo/notmuch
