> I need send file as attachment within Korn shell script. I know how to
> send file contents in message body i.e
> elm -sSubject Address < FILENAME
> How this file can be sent as attachment?
\__ \ _/ -_) V / -_) ' \ UNIX Shell Script Programmers: visit
I'm trying to write a korn, or perl, script, that when kicked off by a cron
job, will traverse/check a directory for updated files (the files always
have the same name in the same directory) and then, if the given file(s)
timestamp(s) (?) have been updated, the script will e-mail them to a user.
The files that I want in the directory are updated every hour. I've been
working on this for a couple of weeks and still haven't gotten the end
result I need. Of course, I'm new at scripting so I'm on a steep learning
I tried running a script using "diff" to find the files whose timestamps
have changed, but I seem to have to have two directories, one to store the
files as they were the last time the script ran, and the other "real"
directory with all of the "real" files with the current timestamps so they
have something to compare to. Someone said that maybe you can "touch" the
files. I've figured out what they were refering to with the "touch" command
(to update the timestamp), but I'm not exactly sure how I can fit that in to
accomplish my task.
I tried using Perl, but again I'm learning Perl and unix shell scripting so
I'm trying to learn both and accomplish a task at the same time. I've seen
that scripting is awesome. I just have to get the basics down. This stuff
Any ideas would be greatly appreciated.
Thanks in advance,