How to read file content and send email on Debian Bullseye

^Bart gabriele1NOSPAM at hotmail.com
Sun Feb 5 06:09:33 EST 2023


> xdg-email appears to be for interactive use (it opens the user's
> "preferred email composer"); I think sendmail would work much better
> from a script.

Like what I said in another post I think I could use ssmtp than 
xdg-email or sendmail...

> Otherwise, I had the same initial thought, to add to and/or build a
> wrapper around the existing lftp script.

I'd like to know if there's a code made from lftp to understand when an 
upload file is finished but certainly I can read it from the log file 
and I think it couldn't be hard to find a value in a *.txt file and if 
this value is inside of it to send an email like "ok" otherwise a 
message with "k.o.".

Regards.
^Bart


More information about the Python-list mailing list