# unset possible system-defined aliases. unalias l ll lll llll la laa &> /dev/null unset l ll lll llll la laa &> /dev/null # list files in dir. l() { ls -lhvt --si --group-directories-first "$@" } # list all files in dir, incl. hidden files. ll() { ls -lAhvt --si --group-directories-first "$@" } # list files in tree structure. # usage: lll [DEPTH] [DIRS] lll() { local IFS=$'\n' local depth="${1}" local target=("${@:2}") [[ "${target}" = "" ]] && target="." [[ "${depth}" = "" ]] && depth=666 [[ "${depth}" = "-" ]] && depth=666 tree -a -L "${depth}" -- "${target[@]}" } # list files recursively. llll() { ls -RlAhvt --si --group-directories-first "$@" } # list files alphabetically. la() { ls -lh --si --group-directories-first "$@" } # list all files alphabetically. laa() { ls -lAh --si --group-directories-first "$@" } # export. export -f l ll lll llll la laa