4 ms·
> it doesn't launch a new process for each line like exec does Exec doesn't either if you use "+" as a terminator: find . $(options) -exec command {} \;
by masklinn 14y ago
> it doesn't launch a new process for each line like exec does
Exec doesn't either if you use "+" as a terminator:
find . $(options) -exec command {} \;
executes one command per match,
find . $(options) -exec command {} +
executes a single command with all matches
> exec is just an ugly hack on find
Obvious and complete nonsense, -exec is both an important predicate of find and a useful and efficient tool.
-print0/xargs -0, now that is a hack.
- gnaritas 14y agoYou apparently missed the part where I said "but far more importantly".