diff --git a/update.rb b/update.rb index 3e047df..a3b2752 100644 --- a/update.rb +++ b/update.rb @@ -6,7 +6,7 @@ log_dir = LOG_DIR users.each do |user| size = `du -B1 #{shot_dir}#{user}/ | awk {'print $1'} | head -n 1` - count = `ls -1 #{shot_dir}#{user}/ | wc -l | head -n 1` + count = `find #{shot_dir}#{user}/ -maxdepth 1 -type f | wc -l | head -n 1` [size,count].each do |x| x.delete! "\n"