7 if expr "$pattern" : '.*/' >/dev
/null
17 #echo -e "\r\e[KDepth $depth" >&2
18 find "${@:-.}" -mindepth "$depth" -maxdepth "$depth" -xdev \
19 \
( -$matchtype "*$pattern*" -printf "1 %p\n" \
) -o \
20 \
( -type d
-printf "3 %p\n" \
) 2>/dev
/null
21 cont
=`find "${@:-.}" -mindepth "$depth" -maxdepth "$depth" -xdev -printf 1 -quit 2>/dev/null`
22 [ -z "$cont" ] && break
39 if [ $SECONDS -gt ${t:-0} ]
42 if [ ${#x} -gt $
[cols-3
] ]
48 echo -ne "\r\e[K$x" >&2
64 ff - Find files horizontally, ie. a whole directory level at a time, across subtrees
68 ff <B<pattern>> [B<path>-1] [B<path>-2] ... [B<path>-n]
72 Search files which name matches to B<pattern> in B<path>s directories recursively, case-insensitively.
73 The file's path is matched if B<pattern> contains '/'.
74 Searching is done horizontaly, ie. scan the upper-most directory level first completely,
75 then dive into the next level and scan those directories before moving to the 3rd level deep, and so on.
76 This way users usually find what they search for more quickly.