New answers tagged

0

du naturally traverses the directory hierarchy and awk can perform the filtering so something like this may be sufficient: du -ak | awk 'BEGIN {sum=0} /\.jpg$/ {sum+=$1} END {print sum}' This works without GNU.



Top 50 recent answers are included