- 论坛徽章:
- 0
|
看来使用管道时,xargs接收整个命令所有输出,射程更远一些啊,而采用find后直接exec只接受exec之前的条件输出啊,要使其完整接收,必须加括号。可是find的manual里说除非遇到;才结束,但是加不加括号的输出都是一样的,也没看到;出来。咋解释??
ACTIONS
-exec command ;
Execute command; true if 0 status is returned. All following
arguments to find are taken to be arguments to the command until
an argument consisting of ';' is encountered. The string '{}'
is replaced by the current file name being processed everywhere
it occurs in the arguments to the command, not just in arguments
where it is alone, as in some versions of find. Both of these
constructions might need to be escaped (with a '\') or quoted to
protect them from expansion by the shell. The command is exe-
cuted in the starting directory. |
|