ls -ltr ??src/*.err is equivalent to what syntax in find
I only want to list *.err files in ??src DIRs
Thank you much for any help you can provide.
[/code]---------- Post updated at 08:55 AM ---------- Previous update was at 08:39 AM ----------
find . -type d -name '??src' seems to work for me, but it also shows beyond . directory.
@Scrutinizer, all wildcards for find must be quoted, including -name "*.err" , otherwise the shell might substitute it by matches in the current directory.
--
For only listing the files I would use your ls command.
For doing more with each file I propose a for loop
for i in ??src/*.err
do
if [ -f "$i" ]
then
echo "do something with file '$i'"
fi
done