Hi,
I have the following which works but think there must be a easier one-liner way of doing this which involves not writing to a file but have failed to find something that works
This is what I have:
Code:
du -m $i > filesize.txt
FILESIZE=$`cat "filesize.txt" | cut -f1
rm filesize.txt
I then use the FILESIZE to compare to a number.
cheers,
Tara