Skip to content

Instantly share code, notes, and snippets.

@wchargin
Created February 6, 2014 07:42
Show Gist options
  • Save wchargin/8839874 to your computer and use it in GitHub Desktop.
Save wchargin/8839874 to your computer and use it in GitHub Desktop.
#!/bin/sh
# whybig - determine which files/subdirectories are biggest
# usage: whybig [directory]
# directory defaults to "."
dir=$1
if [ -z $1 ]; then dir="."; fi
du $dir -d 1 | sort -rn
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment