#!/bin/sh # Check if at least one argument is passed if [ "$#" -eq 0 ]; then echo "Usage: $0 [ ...]" exit 1 fi # Loop through all the arguments and perform 'du -sh' on each for item in "$@"; do du -sh "$item" done | sort -h