find large files

#!/bin/bash

########################################
###
### finds large files under current dir tree
###
########################################

########################################
###
### 2009-12-01:dmarsh:find large files under current mount point
### 2010-04-13:dmarsh:changed echo cmd to print -u2 so message goes to stderr
### 2013-05-22:davidm:explicitly set path var, remove hardcoded links
### 2015-12-02:davidm:pass either path or default to current dir if none given
###
########################################

set -e
set -u
PATH='/usr/bin:/bin'
dir="${1:-.}"
cmd="find ${dir} -xdev -type f -size +1048576c -exec du -sk {} \; 2>/dev/null | sort -n | tail -128"
#print -u2 ${cmd}
eval ${cmd}