muttmua / mutt

The Mutt E-Mail Client github mirror. Please use gitlab for issues/pull requests.
https://gitlab.com/muttmua/mutt
Other
217 stars 26 forks source link

Option to ask for PGP encryption from the command line in batch mode #14

Open ronohara opened 7 months ago

ronohara commented 7 months ago

I am looking for a description of how to request PGP encryption of an outgoing message in batch mode with mutt.

The command I have been using is : (${VER} is already set)

echo "${USER} spreadsheet ${VER}" | mutt -s "Re: spreadsheet: ${VER}" -a ROH-my-file-${VER}.ods -- ron.ohara54@gmail.com

If I send this message and attached file interactively I can encrypt it just fine. But I am looking for a way to do the same thing from the command line - so using an extra switch to request encryption ... or setting up something in the 'muttrc' file

This is to do a cron job backup of this file (encrypted) into my email as part of my disaster recovery setup.

Any pointers ?