du -hc *zip shows me total size of zip files in a folder, but it shows also every single file size of the folder. I only need total size.
Is there way to show the total size of a folder without showing single file sizes?
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It only takes a minute to sign up.Sign up to join this community
du -ch *zip | grep total
Just add a grep statement in the end.
If you are against
grep, you can use,
du -s *zip -s, --summarize display only a total for each argument
you can use
du -ch *.zip | tail -1 . last line of
du -ch is total. If the files have
total.zip grep total will return that one as well.