Hi,
Post by Matto FransenI have a folder on a IMAP account with a number of PGP-ecrypted
mail messages. I would like to have those decrypted somewhere, so
I can grep or otherwise search for some content.
The messages can all be decrypted with my key, of course.
Is there a handy way to save these messages in decrypted form, or
extract the decrypted content and save that somewhere?
With the offline help of Gijs Hillenius this is the current solution:
- Select messages
- Run gnus-summary-save-article-file
- At the prompt, give the name of the file to save to
Select messages:
---------------
This can be either be done by marking some
messages with the '#' key, or by giving a number
as argument to gnus-summary-save-article-file:
(gnus-summary-save-article-file 42)
will save the next 42 messages as plain text
(gnus-summary-save-article-file -42)
will save the previous 42 messages as plain text
Run gnus-summary-save-article-file:
----------------------------------
A single message can be saved as plain text with
the keys 'O f'
The messages marked with '#' can be saved as plain
text with the keys 'O f'
At the prompt, give the name of the file to save to
---------------------------------------------------
In either method, single file, marked file, or a
number of files, the name of the file to save the
plain texzt version to, has to be supplied.
After the first messages has been saved this way,
the supplied name will be prompted as default.
This means, that just typen RET (Enter-key), the
plain text version of next message will appended
to file, the plain text version of first messsage
was saved into.
This behaviour can be changed by setting
gnus-prompt-before-saving to 't'. In that case,
you are only prompted once for the file name, or
by setting gnus-prompt-before-saving to 'nil, in
which case Gnus will simply save all the articles
in the default files.
See:
https://www.gnu.org/software/emacs/manual/html_node/gnus/Saving-Articles.html
The messages are decrypted and then saved,
starting from the "From: <email-address" line.
A blank line is inserted between the messages.
So, the answer was in the friendly manual .,,
Best regards,
Matto