bash file counting

This commit is contained in:
Zynh Ludwig 2024-08-01 02:59:26 -07:00
parent 56a95dba69
commit f85b574a5d

View file

@ -25,7 +25,9 @@ in
target=''${args[1]}
if [ -d "''$target" ]; then
if ${pkgs.findutils}/bin/find "''$target" -maxdepth 0 -empty; then
files=(''$target"/*")
if [ ''$(''$files[@]) -gt 0 ]; then
echo "~ Found Files at ''$target ~"
else
echo "~ No Files in ''$target ~"