Skip to content

Instantly share code, notes, and snippets.

@thebouv
Last active August 13, 2025 12:18
Show Gist options
  • Save thebouv/8657674 to your computer and use it in GitHub Desktop.
Save thebouv/8657674 to your computer and use it in GitHub Desktop.
ducks: linux command for the 10 largest files in current directory
du -cks * | sort -rn | head -11
# Usually set this up in my bash profile as an alias:
# alias ducks='du -cks * | sort -rn | head -11'
# Because it is fun to type ducks on the command line. :)
@dashdsrdash
Copy link

You can cut out the sort if you are willing to accept that you are only checking on files, not recursively into folders:

ls -AlS |head -11

I often want to know most recent files, so -t is useful.

@zchrissirhcz
Copy link

zchrissirhcz commented Aug 13, 2025 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment