Hacker News new | ask | show | jobs
by to3m 4254 days ago
File names often have spaces in them, but very rarely newlines. Based on xargs's current behaviour, it's clearly no problem to just not support certain characters in file names by default. I just think it would have been more useful for it to not support a smaller set of names.
1 comments

You would be amazed what various broken tools can produce for filenames.
I can't decide if this is a rebuttal, or not ;) - assuming it is, note that the number of possible paths containing newlines OR spaces is smaller than the number of possible paths containing only newlines, so an xargs that didn't handle newlines by default would still be supporting more possible paths than it does in its current state!
Only the other week I managed to mouse-twitch into existence a file that rm refused to remove.