I'm not really sure you're contradicting me – where did I say that if you constantly had to specify the 'work properly' option to find, something was necessarily wrong with find?
Well, a command where one always ends up some specific optionis, I agree, a command that should have better defaults. But both find and xargs, I sometimes use with those options, sometimes without. So I'm not sure what you feel should be improved about the situation, or how.
The reductio ad absurdam would be for the shell to have just one command: dwim (-8
Well, I haven't exactly worked out all the details either, as I'm sure you know perfectly well.
But it seems to me that it ought not to be beyond the wit of humankind to devise a system whereby the list of filenames output by find does not need to be explicitly specified every single time as being in one or another particular serialised representation, when that selection could in principle be automatically inferred by knowing the consumer of the data. Programming languages, for example, have a range of perfectly good mechanisms whereby you can return one type and also provide a default conversion to one or more other types for clients who would have preferred those, and then you don't have to write the conversions out longhand at every call site.
If there's a movement to have Unix commands output some form of structured data instead of a raw octet stream that is in many cases assumed to be textual, I just bet people would choose either MIME or XML.
I think I'd rather keep typing -print0 and -0 than take the risk!
The reductio ad absurdam would be for the shell to have just one command: dwim (-8
But it seems to me that it ought not to be beyond the wit of humankind to devise a system whereby the list of filenames output by
find
does not need to be explicitly specified every single time as being in one or another particular serialised representation, when that selection could in principle be automatically inferred by knowing the consumer of the data. Programming languages, for example, have a range of perfectly good mechanisms whereby you can return one type and also provide a default conversion to one or more other types for clients who would have preferred those, and then you don't have to write the conversions out longhand at every call site.I think I'd rather keep typing -print0 and -0 than take the risk!