I did a loop process using Bash for
command, on Linux mint, with the input range is from previous process comes from find
, but it'd apparently and clearly did it in batch process relative to terminal output, rather than the immediate one if find
range is explicit and performed to give a terminal output.
mine is;
IFS=$'\n'
for s in $(find ~+ -type f -regextype posix-extended -iregex ".*/data\.(tmp|bak)" -printf '%p\n')
{
echo $s
}
it'll be still without any output for 100 sec. or more, rather than straightly shows some on terminal.
How to make it work as nearly fast as find
instructed alone and directly ? thanks inadvance, I appreciate it.
-exec ... {} +
will still of course batch, but it might depend on the implementation how much it does. On Linux, GNU find seems to batch up to a command line length of 128 kB, even though the actual limit is higher. – ilkkachu Sep 22 '18 at 10:51