ok, so I'm going out of my mind.
I'm trying to send an email attachment I generate from a find command.
it does indeed send the email with the attachment but the file is empty..
the command is as follows:
Code:
find /media/2A06DF4A06DF1623/media/limited\ time\ only/ -mindepth 1 -maxdepth 1 -type d -mtime +120 -printf "%f\n" > /tmp/file.txt | mutt -s "to be deleted" myemail@gmail.com -a /tmp/file.txt
the above generates the 0 byte email attachment
If I go to /tmp and view the file.txt I see a 4Kb file with contents.
If I create a filed with a few chars.... say fish.txt and use the following:
Code:
find /media/2A06DF4A06DF1623/media/limited\ time\ only/ -mindepth 1 -maxdepth 1 -type d -mtime +120 -printf "%f\n" > /tmp/file.txt | mutt -s "to be deleted" myemail@gmail.com -a /tmp/fish.txt
(yes I know it generates file.txt and I send fish.txt)
then I get content in the attachment...
So I am thinking it must somehow be the file itself.. but I cannot spot the problem...
anyone have any ideas?