Announcements and discussions for Gnus, the GNU Emacs Usenet newsreader
 help / color / mirror / Atom feed
From: Dmitry Alexandrov <321942@gmail.com>
To: "Loris Bennett" <loris.bennett@fu-berlin.de>
Cc: info-gnus-english@gnu.org
Subject: Re: Secondary-select-method-specific gnus-message-archive-group
Date: Fri, 14 Oct 2016 22:30:21 +0300	[thread overview]
Message-ID: <87d1j2afua.fsf@gmail.com> (raw)
In-Reply-To: <87lgxr5qc2.fsf@hornfels.zedat.fu-berlin.de> (Loris Bennett's message of "Fri, 14 Oct 2016 09:42:37 +0200")

> I have tried to set up different values for
>
>   gnus-message-archive-group
>
> for different secondary select methods like this:
>
>      (nnimap "gmx"
>              (nnimap-stream tls)
>              (gnus-message-archive-group "nnimap+gmx:Gesendet")
>              (nnimap-address "imap.gmx.com"))
>      (nnimap "gmail"
>              (nnimap-stream ssl)
>              (nnimap-server-port 993)
>              (remove-prefix nnimap)
>              (gnus-message-archive-group "nnimap+gmail:Sent Mail")
>              (nnimap-address "imap.gmail.com"))
>
> I do get different values for gnus-message-archive-group (I actually have a
> few more select methods), but I don't always get the one I am expecting.
>
> Can anyone tell me how the values are triggered?

I am not sure, whether message archive groups do have anything to do with select methods.  Select methods are about receiving mail, while archive group is chosen when you start to compose a message.

I’m using the following piece of config to place a letter in a current group (in particular that means to the same group where the message I’m replying is stored) or in ‘INBOX’ by default:

--8<---------------cut here---------------start------------->8---
(setq gnus-message-archive-group
      '((cond
         ((string-prefix-p "nnimap+" group) group)
         (t "nnimap+g:INBOX"))))
--8<---------------cut here---------------end--------------->8---

(By the way, why don’t you do the same?  What is the point to separate sent letters from received ones?)

Anyway, what you probably want to do may look like that, I guess:

--8<---------------cut here---------------start------------->8---
(setq gnus-message-archive-group
      '((cond
         ((string-prefix-p "nnimap+gmx:" group) "nnimap+gmx:Gesendet")
         ((string-prefix-p "nnimap+gmail:" group) "nnimap+gmail:Sent Mail")
         (t "nnimap+gmail:Sent Mail"))))
--8<---------------cut here---------------end--------------->8---

_______________________________________________
info-gnus-english mailing list
info-gnus-english@gnu.org
https://lists.gnu.org/mailman/listinfo/info-gnus-english

  reply	other threads:[~2016-10-14 19:30 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-14  7:42 Loris Bennett
2016-10-14 19:30 ` Dmitry Alexandrov [this message]
2024-01-13 13:23   ` Loris Bennett

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87d1j2afua.fsf@gmail.com \
    --to=321942@gmail.com \
    --cc=info-gnus-english@gnu.org \
    --cc=loris.bennett@fu-berlin.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).