#!/bin/sh find /cicd/BuildRoot -maxdepth 1 -type d | while read dir; do count=$(find "$dir" -type f | wc -l) echo "$dir : $count" done