On Sat, Oct 09, 2010 at 12:06:21AM +0200, Sven Mascheck wrote: > On Mon, Sep 20, 2010 at 09:14:15AM -0400, Greg Wooledge wrote: > > unset array > > while IFS= read -r -d '' f; do array+=("$f"); done \ > > < <(find . -name '*.c' -print0) > > vi "${arr...@]}"
> As you mention -exec yourself, what about simply > > find . -type f -name '*.c' -exec sh -c 'vi "$@"' find-sh {} + > find . -type f -name '*.c' -exec vi {} + If there is an absolute requirement to put *all* the files on a single command, "-exec +" may fail to satisfy it. It might break up the files into groups. If it's acceptable to process the files in groups (i.e. if the example were something that isn't vi) then "-exec +" is a great alternative.