|
From: | Richard White |
Subject: | bug#21712: Suspected bug in find -exec '+' |
Date: | Mon, 19 Oct 2015 12:33:34 +0100 |
The find utility supports execution of a nominated command per file found. The command argument list is terminated with a ';' parameter. The enhanced GNU version specifies an alternative version of the –exec option using a '+' list terminator. This option is provided to support an xargs-like batched execution of the nominated command resulting in greater efficiency. It seems like find –exec ';' and find –exec '+' do not behave consistently with regard to '{}' argument expansion. An example: mkdir /tmp/test cd /tmp/test touch a b find . –type f –exec echo Prefix{}Suffix ';' è Prefix./bSuffix è Prefix./aSuffix find . –exec echo Prefix{}Suffix '+' è ./b ./a Is the latter result correct? I would have expected the same result as for the ';' version? Richard White
|
[Prev in Thread] | Current Thread | [Next in Thread] |