Discussion:
gnus-posting-styles vs compose-mail
Kevin Ryde
2014-07-29 08:58:49 UTC
Permalink
Does gnus-posting-styles rules have anything to notice when a message
has been started by `compose-mail', and perhaps the parameters on that
compose-mail?

I see dynamic bindings of the compose-mail args are visible as variables
`to', `subject', etc, but I wonder if that should be relied on.

I thought to suppress Gcc on some semi-automated mails. I got the
effect I wanted from code in gnus-message-archive-group like below, and
then wondered if it too already had anything to notice compose-mail or
match headers. (At the gnus-message-archive-group stage the buffer has
headers ready to consult, I believe.)

(setq gnus-message-archive-group
'((if (equal (message-fetch-field "To") "***@example.com")
nil
"sent")))
Eric Abrahamsen
2014-07-31 02:10:56 UTC
Permalink
Post by Kevin Ryde
Does gnus-posting-styles rules have anything to notice when a message
has been started by `compose-mail', and perhaps the parameters on that
compose-mail?
I see dynamic bindings of the compose-mail args are visible as variables
`to', `subject', etc, but I wonder if that should be relied on.
I thought to suppress Gcc on some semi-automated mails. I got the
effect I wanted from code in gnus-message-archive-group like below, and
then wondered if it too already had anything to notice compose-mail or
match headers. (At the gnus-message-archive-group stage the buffer has
headers ready to consult, I believe.)
(setq gnus-message-archive-group
nil
"sent")))
I think no, posting styles won't look at the headers of messages you
compose. My understanding is the styles are only in effect for a) group
names, when you're composing a message to a specific group, and b)
messages you're replying to, in which case the styles match on the
headers of the original (received) message. I don't think you can do it
based on outgoing message headers. How would gnus know which of the
gnus-posting-style entries were meant to match on outgoing messages, and
which meant to match on replied messages?

I've thought off and on about a wrapper for mail composition, which
would first query you for a few headers, and then set up the message
accordingly. That would provide a place to run hooks like what you want,
but until someone writes that wrapper...

Yours,
Eric
Kevin Ryde
2014-08-02 03:44:59 UTC
Permalink
Post by Eric Abrahamsen
I think no, posting styles won't look at the headers of messages you
compose.
Hmm, yes, a bit early.
Post by Eric Abrahamsen
How would gnus know which of the
gnus-posting-style entries were meant to match on outgoing messages, and
which meant to match on replied messages?
Oh, it would have to be some different pattern form or something.
I suppose there's only a few common compose-mail starts.
M-x report-emacs-bug or M-x debian-bug would be main ones.
Eric Abrahamsen
2014-08-04 02:12:58 UTC
Permalink
Post by Kevin Ryde
Post by Eric Abrahamsen
I think no, posting styles won't look at the headers of messages you
compose.
Hmm, yes, a bit early.
Post by Eric Abrahamsen
How would gnus know which of the
gnus-posting-style entries were meant to match on outgoing messages, and
which meant to match on replied messages?
Oh, it would have to be some different pattern form or something.
I suppose there's only a few common compose-mail starts.
M-x report-emacs-bug or M-x debian-bug would be main ones.
FWIW, Gnorb has something halfway similar to this with BBDB-based
posting styles. Basically you write a set of posting-style rules,
similar to gnus posting styles but matching on BBDB record fields. That
will set fields on the composed message.

That means it's contact-centric, which isn't what you're asking for. You
need to use `gnorb-bbdb-mail' rather than `bbdb-mail' to make it work.
But the end effect would be similar: eg "Any message composed to a
contact with a 'foo' field value of 'bar', set my outgoing Organization
header to 'baz." Or what have you.

See `gnorb-bbdb-posting-styles' for details.

https://github.com/girzel/gnorb
jenia.ivlev
2014-09-12 23:55:11 UTC
Permalink
Hello.

Im having trouble with finding the parent article of a sent message in
"Summary-mode".

I press `^` in the sent folder, summary mode, which is bound to the
function "gnus-summary-refere-parent-article". It tells me "No reference
in article x".

Does anyone know how to fix this?

Thanks in advnace for your kind help and time.
jenia
Andreas Schwab
2014-09-13 08:29:34 UTC
Permalink
Post by jenia.ivlev
I press `^` in the sent folder, summary mode, which is bound to the
function "gnus-summary-refere-parent-article". It tells me "No reference
in article x".
Does anyone know how to fix this?
If there is no reference then that article has no parent.

Andreas.
--
Andreas Schwab, ***@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
Loading...