1
0
Fork 0
mirror of https://github.com/notwa/rc synced 2024-11-05 04:29:03 -08:00
rc/sh/is_empty

9 lines
168 B
Text
Raw Normal View History

2013-06-28 05:22:14 -07:00
#!/usr/bin/env bash
is_empty() {
while read -r; do
[ ! -d "$REPLY" ] && [ -s "$REPLY" ] && return 1
done < <(find ${1:-.})
return 0
}
is_empty "$@"