Gnus development mailing list
 help / color / mirror / Atom feed
* set up Gnus to work with a remote system mailserver (with Dovecot?)
@ 2022-04-07  1:17 Emanuel Berg
  2022-04-07  2:34 ` Byung-Hee HWANG
                   ` (2 more replies)
  0 siblings, 3 replies; 57+ messages in thread
From: Emanuel Berg @ 2022-04-07  1:17 UTC (permalink / raw)
  To: ding

o/

Anyone knows to setup Gnus to work with a remote system
mailserver? I've heard it is IMAP and you are supposed to do
accomplish this with something called Dovecot.

That's all I know tho ...

References to tutorials or HOWTOs appreciated as well.

TIA

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07  1:17 set up Gnus to work with a remote system mailserver (with Dovecot?) Emanuel Berg
@ 2022-04-07  2:34 ` Byung-Hee HWANG
  2022-04-07  3:08   ` Emanuel Berg
  2022-04-07  8:51 ` set up Gnus to work with a remote system mailserver (with Dovecot?) Uwe Brauer
  2022-04-07  9:31 ` Christian Barthel
  2 siblings, 1 reply; 57+ messages in thread
From: Byung-Hee HWANG @ 2022-04-07  2:34 UTC (permalink / raw)
  To: ding

Emanuel Berg <moasenwood@zoho.eu> writes:

> o/
>
> Anyone knows to setup Gnus to work with a remote system
> mailserver? I've heard it is IMAP and you are supposed to do
> accomplish this with something called Dovecot.
>
> That's all I know tho ...
>
> References to tutorials or HOWTOs appreciated as well.
>
> TIA

nnimap? If True, i'm using it with Gmail for 13 years.
The only my concern, is Gmail's oauth2.

So now i'm wondering... Oauth2 is so fear thing to the Gnus fan.

Sincerely, Gnus fan Byung-Hee

-- 
^고맙습니다 _地平天成_ 감사합니다_^))//


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07  2:34 ` Byung-Hee HWANG
@ 2022-04-07  3:08   ` Emanuel Berg
  2022-04-07  7:47     ` Andreas Schwab
  0 siblings, 1 reply; 57+ messages in thread
From: Emanuel Berg @ 2022-04-07  3:08 UTC (permalink / raw)
  To: ding

Byung-Hee HWANG wrote:

>> Anyone knows to setup Gnus to work with a remote system
>> mailserver? I've heard it is IMAP and you are supposed to
>> do accomplish this with something called Dovecot.
>>
>> That's all I know tho ...
>>
>> References to tutorials or HOWTOs appreciated as well.
>>
>> TIA
>
> nnimap? If True, i'm using it with Gmail for 13 years.
> The only my concern, is Gmail's oauth2.

Okay check, I'll use the nnimap backend! Makes sense, if it is
IMAP LOL :)

But how do I set it up on the remote system?

I have a mail on that system, incal@dataswamp.org and it works
to mail there, but, in order to check it out I do first ssh
and then use the mail(1) utility.

So the situation is, on the local system, Gnus, on the remote,
mail. The local is Debian and the remote OpenBSD; however
Linux and OpenBSD (or OpenBSD and Linux if you prefer) seems
to have the same mail(1) just looking at an identical (?) man
page from both systems ...

Yeah, should have a --version but doesn't ...

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07  3:08   ` Emanuel Berg
@ 2022-04-07  7:47     ` Andreas Schwab
  2022-04-07  8:07       ` Emanuel Berg
  0 siblings, 1 reply; 57+ messages in thread
From: Andreas Schwab @ 2022-04-07  7:47 UTC (permalink / raw)
  To: ding

On Apr 07 2022, Emanuel Berg wrote:

> I have a mail on that system, incal@dataswamp.org and it works
> to mail there, but, in order to check it out I do first ssh
> and then use the mail(1) utility.

And how does mail access the mailbox?

-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510  2552 DF73 E780 A9DA AEC1
"And now for something completely different."


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07  7:47     ` Andreas Schwab
@ 2022-04-07  8:07       ` Emanuel Berg
  2022-04-07  8:12         ` Emanuel Berg
  0 siblings, 1 reply; 57+ messages in thread
From: Emanuel Berg @ 2022-04-07  8:07 UTC (permalink / raw)
  To: ding

Andreas Schwab wrote:

>> I have a mail on that system, incal@dataswamp.org and it
>> works to mail there, but, in order to check it out I do
>> first ssh and then use the mail(1) utility.
>
> And how does mail access the mailbox?

I don't know, it reads, in my case, /var/mail/incal ?

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07  8:07       ` Emanuel Berg
@ 2022-04-07  8:12         ` Emanuel Berg
  2022-04-07  8:27           ` Emanuel Berg
  0 siblings, 1 reply; 57+ messages in thread
From: Emanuel Berg @ 2022-04-07  8:12 UTC (permalink / raw)
  To: ding

>>> I have a mail on that system, incal@dataswamp.org and it
>>> works to mail there, but, in order to check it out I do
>>> first ssh and then use the mail(1) utility.
>>
>> And how does mail access the mailbox?
>
> I don't know, it reads, in my case, /var/mail/incal ?

Maybe the backend `nnmbox' ...

(info "(gnus) Unix Mail Box")

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07  8:12         ` Emanuel Berg
@ 2022-04-07  8:27           ` Emanuel Berg
  2022-04-10 11:47             ` Byung-Hee HWANG
  0 siblings, 1 reply; 57+ messages in thread
From: Emanuel Berg @ 2022-04-07  8:27 UTC (permalink / raw)
  To: ding

>>>> I have a mail on that system, incal@dataswamp.org and it
>>>> works to mail there, but, in order to check it out I do
>>>> first ssh and then use the mail(1) utility.
>>>
>>> And how does mail access the mailbox?
>>
>> I don't know, it reads, in my case, /var/mail/incal ?
>
> Maybe the backend `nnmbox' ...
>
> (info "(gnus) Unix Mail Box")

... and then?

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07  1:17 set up Gnus to work with a remote system mailserver (with Dovecot?) Emanuel Berg
  2022-04-07  2:34 ` Byung-Hee HWANG
@ 2022-04-07  8:51 ` Uwe Brauer
  2022-04-07  8:58   ` Emanuel Berg
  2022-04-07 10:28   ` Eric S Fraga
  2022-04-07  9:31 ` Christian Barthel
  2 siblings, 2 replies; 57+ messages in thread
From: Uwe Brauer @ 2022-04-07  8:51 UTC (permalink / raw)
  To: ding

[-- Attachment #1: Type: text/plain, Size: 708 bytes --]

>>> "EB" == Emanuel Berg <moasenwood@zoho.eu> writes:

> o/
> Anyone knows to setup Gnus to work with a remote system
> mailserver? I've heard it is IMAP and you are supposed to do
> accomplish this with something called Dovecot.

Right, I used it for years, but I gave it up when my University
switched, to, guess, GMAIL.

At least 3 years ago, dovecot was not only slow with GMAIL, but it also
tried re download already downloaded messages.

So I use gnus nnimap backend right now (academic institutions,
fortunately  do not use oauth2, for the moment, and I hope it stays that
way). Works reasonable well, sometimes I have to kill the process, but
other than that it is ok

Uwe Brauer 

[-- Attachment #2: smime.p7s --]
[-- Type: application/pkcs7-signature, Size: 5673 bytes --]

^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07  8:51 ` set up Gnus to work with a remote system mailserver (with Dovecot?) Uwe Brauer
@ 2022-04-07  8:58   ` Emanuel Berg
  2022-04-07 10:28   ` Eric S Fraga
  1 sibling, 0 replies; 57+ messages in thread
From: Emanuel Berg @ 2022-04-07  8:58 UTC (permalink / raw)
  To: ding

Uwe Brauer wrote:

>> Anyone knows to setup Gnus to work with a remote system
>> mailserver? I've heard it is IMAP and you are supposed to
>> do accomplish this with something called Dovecot.
>
> Right, I used it for years, but I gave it up when my
> University switched, to, guess, GMAIL.
>
> At least 3 years ago, dovecot was not only slow with GMAIL,
> but it also tried re download already downloaded messages.
>
> So I use gnus nnimap backend right now (academic
> institutions, fortunately do not use oauth2, for the moment,
> and I hope it stays that way). Works reasonable well,
> sometimes I have to kill the process, but other than that it
> is ok

How do you use it? This isn't Gmail but the mail server on the
remote system.

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07  1:17 set up Gnus to work with a remote system mailserver (with Dovecot?) Emanuel Berg
  2022-04-07  2:34 ` Byung-Hee HWANG
  2022-04-07  8:51 ` set up Gnus to work with a remote system mailserver (with Dovecot?) Uwe Brauer
@ 2022-04-07  9:31 ` Christian Barthel
  2022-04-07 10:57   ` Emanuel Berg
                     ` (2 more replies)
  2 siblings, 3 replies; 57+ messages in thread
From: Christian Barthel @ 2022-04-07  9:31 UTC (permalink / raw)
  To: ding; +Cc: Emanuel Berg

On Thursday, April 07, 2022, Emanuel Berg wrote:

> Anyone knows to setup Gnus to work with a remote system mailserver?
> I've heard it is IMAP and you are supposed to do accomplish this with
> something called Dovecot. [..]

nnimap is the way to go, see (info "(gnus) Using IMAP")

As far as I remember, the system you’re referring to does not expose 
Dovecot on a TCP port nor does it run Dovecot as a daemon.  In this
case, you can use the Dovecot imap binary.  The configuration should be
something like this:

--8<---------------cut here---------------start------------->8---
(setq gnus-select-method
  '(nnimap "Mail"
   (nnimap-stream shell)
   (nnimap-shell-program
      "ssh user@host /usr/local/libexec/dovecot/imap -o
      mail_location=maildir:~/Maildir/:LAYOUT=fs")))
--8<---------------cut here---------------end--------------->8---

(remove the “ssh user@host” if you’re working locally)

So, instead of talking with an IMAP Service on a network socket, it
executes the shell command and reads mails from there (stdin/stdout).
Make sure to setup ~/Maildir/ i.e. your incoming mail must be directed
into the ~/Maildir folder.

To redirect your incoming mail to fdm(1), you have to setup the
“.forward” file in your home directory:

--8<---------------cut here---------------start------------->8---
# cat ~/.forward
|/usr/local/bin/fdm -m -a stdin fetch
--8<---------------cut here---------------end--------------->8---

With fdm(1), something like this should work:

--8<---------------cut here---------------start------------->8---
# cat ~/.fdm.conf
action "inbox" maildir "/home/username/Maildir/"
match all action "inbox"
--8<---------------cut here---------------end--------------->8---

And then, you have to setup SMTP to send emails.


Some additional pointers:
https://github.com/nicm/fdm/blob/master/MANUAL#L730
https://dovecot.org/pipermail/dovecot/2009-February/037682.html
https://ding.gnus.narkive.com/8JpLY6yI/how-to-debug-nnimap-stream-shell
   (haven’t used that but that seems helpful for debugging)
-- 
Christian Barthel


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07  8:51 ` set up Gnus to work with a remote system mailserver (with Dovecot?) Uwe Brauer
  2022-04-07  8:58   ` Emanuel Berg
@ 2022-04-07 10:28   ` Eric S Fraga
  2022-04-07 16:43     ` Russ Allbery
  1 sibling, 1 reply; 57+ messages in thread
From: Eric S Fraga @ 2022-04-07 10:28 UTC (permalink / raw)
  To: ding

On Thursday,  7 Apr 2022 at 10:51, Uwe Brauer wrote:
> (academic institutions, fortunately do not use oauth2, for the moment,
> and I hope it stays that way). 

I wish this were true.  😞 Mine, which uses Exchange, moved to
multi-factor authentication (MFA) last year and I could not get gnus to
work with it directly.  Instead, I installed davmail which downloads
from Exchange with MFA just fine and I point gnus to davmail
(i.e. localhost) instead.  Works very well.

For OP, if the mail is actually mbox format in /var/mail/incal, can gnus
use a tramp specification for the file name?  I.e. maybe something like

(setq mail-sources '((file :path "/ssh:user@host:/var/mail/incal")))

might work (untested, of course) but maybe not as it might depend on
what movemail supports?

-- 
Eric S Fraga with org 9.5.2 in Emacs 29.0.50 on Debian 11.3



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07  9:31 ` Christian Barthel
@ 2022-04-07 10:57   ` Emanuel Berg
  2022-04-09 23:23   ` Emanuel Berg
  2022-04-21  1:42   ` Emanuel Berg
  2 siblings, 0 replies; 57+ messages in thread
From: Emanuel Berg @ 2022-04-07 10:57 UTC (permalink / raw)
  To: ding

Christian Barthel wrote:

> So, instead of talking with an IMAP Service on a network
> socket, it executes the shell command and reads mails from
> there (stdin/stdout). Make sure to setup ~/Maildir/ i.e.
> your incoming mail must be directed into the
> ~/Maildir folder.
>
> To redirect your incoming mail to fdm(1), you have to setup
> the “.forward” file in your home directory:
>
> # cat ~/.forward
> |/usr/local/bin/fdm -m -a stdin fetch
>
> With fdm(1), something like this should work:
>
> # cat ~/.fdm.conf
> action "inbox" maildir "/home/username/Maildir/"
> match all action "inbox"

OK, thanks a lot, now it sort of works, only I can't see the
actual mails anywhere?

$ ~/.forward
| /usr/local/bin/fdm -m -a stdin fetch

$ cat ~/.fdm.conf
action "inbox" maildir "/home/incal/Maildir/"
match all action "inbox"

$ echo "n/t" | mail -s "test n/t" incal # this doesn't end up
                                        # in /var/mail/incal
                                        # anymore ...

But it doesn't seem to end up here either, as

$ ls ~/Maildir/**/*
/home/incal/Maildir/dovecot-uidlist
/home/incal/Maildir/dovecot-uidvalidity
/home/incal/Maildir/dovecot-uidvalidity.624ebab8
/home/incal/Maildir/dovecot.index.log

/home/incal/Maildir/cur:

/home/incal/Maildir/new:

/home/incal/Maildir/tmp:

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07 10:28   ` Eric S Fraga
@ 2022-04-07 16:43     ` Russ Allbery
  2022-04-08 10:03       ` Eric S Fraga
  0 siblings, 1 reply; 57+ messages in thread
From: Russ Allbery @ 2022-04-07 16:43 UTC (permalink / raw)
  To: ding

Eric S Fraga <e.fraga@ucl.ac.uk> writes:

> For OP, if the mail is actually mbox format in /var/mail/incal, can gnus
> use a tramp specification for the file name?  I.e. maybe something like

> (setq mail-sources '((file :path "/ssh:user@host:/var/mail/incal")))

> might work (untested, of course) but maybe not as it might depend on
> what movemail supports?

In a similar situation, I use the following configuration:

(setq mail-sources
   '((file :prescript "ssh <remote-host> bin/getmail >%t")))

where bin/getmail is the following shell script:

#!/bin/sh
MAIL="/var/spool/mail/$USER"
TMP="$HOME/tmp/mailbox"
rm -f "$TMP" && movemail "$MAIL" "$TMP" >/dev/null && cat "$TMP"

This is not very robust and if something goes wrong in the middle it can
lose mail, so if there's something more built-in, I'd also love to hear
about it, but it's worked for years.  This assumes that movemail is
installed on the remote system (on Debian, it's provided by the mailutils
package).

-- 
Russ Allbery (eagle@eyrie.org)             <https://www.eyrie.org/~eagle/>


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07 16:43     ` Russ Allbery
@ 2022-04-08 10:03       ` Eric S Fraga
  2022-04-08 11:59         ` Emanuel Berg
  0 siblings, 1 reply; 57+ messages in thread
From: Eric S Fraga @ 2022-04-08 10:03 UTC (permalink / raw)
  To: ding

On Thursday,  7 Apr 2022 at 09:43, Russ Allbery wrote:
> In a similar situation, I use the following configuration:

Interesting.  Should work for the OP (and even if movemail isn't present
on the server, something similar should be possible).

> This is not very robust and if something goes wrong in the middle it can
> lose mail, so if there's something more built-in, I'd also love to hear

You could consider using different temp files each time, using mktemp to
create a temporary file name in your directory and leave it there just
in case, instead of using the same temp file each time.  Then clean up
periodically.  You could even name the temp file using a time stamp.
Just some thoughts.

-- 
Eric S Fraga with org 9.5.2 in Emacs 29.0.50 on Debian 11.3



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-08 10:03       ` Eric S Fraga
@ 2022-04-08 11:59         ` Emanuel Berg
  0 siblings, 0 replies; 57+ messages in thread
From: Emanuel Berg @ 2022-04-08 11:59 UTC (permalink / raw)
  To: ding

Eric S Fraga wrote:

>> In a similar situation, I use the following configuration:
>
> Interesting. Should work for the OP (and even if movemail
> isn't present on the server, something similar should be
> possible).

Is the idea that .forward should put the pipe leading to
fdm(1) into effect, then in .fdm.conf fdm puts the mails in
~/Maildir?

Only this doesn't seem to happen?

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07  9:31 ` Christian Barthel
  2022-04-07 10:57   ` Emanuel Berg
@ 2022-04-09 23:23   ` Emanuel Berg
  2022-04-21  1:42   ` Emanuel Berg
  2 siblings, 0 replies; 57+ messages in thread
From: Emanuel Berg @ 2022-04-09 23:23 UTC (permalink / raw)
  To: ding

Christian Barthel wrote:

> # cat ~/.forward
> |/usr/local/bin/fdm -m -a stdin fetch
>
> With fdm(1), something like this should work:
>
> # cat ~/.fdm.conf
> action "inbox" maildir "/home/username/Maildir/"
> match all action "inbox"

Have you been able to confirm that this indeed moves system
mail from /var/mail/$USER to ~/Maildir if that's what suppose
to happen?

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07  8:27           ` Emanuel Berg
@ 2022-04-10 11:47             ` Byung-Hee HWANG
  2022-04-10 13:13               ` Emanuel Berg
  0 siblings, 1 reply; 57+ messages in thread
From: Byung-Hee HWANG @ 2022-04-10 11:47 UTC (permalink / raw)
  To: ding

Emanuel Berg <moasenwood@zoho.eu> writes:

>>>>> I have a mail on that system, incal@dataswamp.org and it
>>>>> works to mail there, but, in order to check it out I do
>>>>> first ssh and then use the mail(1) utility.
>>>>
>>>> And how does mail access the mailbox?
>>>
>>> I don't know, it reads, in my case, /var/mail/incal ?
>>
>> Maybe the backend `nnmbox' ...
>>
>> (info "(gnus) Unix Mail Box")
>
> ... and then?

Otherwise you do forward to zoho.eu, then you could check
all emails at one account <moasenwood@zoho.eu>.

Honestly, however, fowarding is not easy nowdays.

Sincerely, Gnus fan Byung-Hee

-- 
^고맙습니다 _救濟蒼生_ 감사합니다_^))//


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-10 11:47             ` Byung-Hee HWANG
@ 2022-04-10 13:13               ` Emanuel Berg
  2022-04-11  3:47                 ` Byung-Hee HWANG
  0 siblings, 1 reply; 57+ messages in thread
From: Emanuel Berg @ 2022-04-10 13:13 UTC (permalink / raw)
  To: ding

Byung-Hee HWANG wrote:

>>>>>> I have a mail on that system, incal@dataswamp.org and
>>>>>> it works to mail there, but, in order to check it out
>>>>>> I do first ssh and then use the mail(1) utility.
>>>>>
>>>>> And how does mail access the mailbox?
>>>>
>>>> I don't know, it reads, in my case, /var/mail/incal ?
>>>
>>> Maybe the backend `nnmbox' ...
>>>
>>> (info "(gnus) Unix Mail Box")
>>
>> ... and then?
>
> Otherwise you do forward to zoho.eu, then you could check
> all emails at one account <moasenwood@zoho.eu>.

Yeah but what I would like is incal@dataswamp.org :(

Actually that already works, to /var/mail/incal, but I can't
read or send with Gnus.

> Honestly, however, fowarding is not easy nowdays.

Okay?

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-10 13:13               ` Emanuel Berg
@ 2022-04-11  3:47                 ` Byung-Hee HWANG
  2022-04-11  4:03                   ` Byung-Hee HWANG
  2022-04-12  6:00                   ` Emanuel Berg
  0 siblings, 2 replies; 57+ messages in thread
From: Byung-Hee HWANG @ 2022-04-11  3:47 UTC (permalink / raw)
  To: ding

Emanuel Berg <moasenwood@zoho.eu> writes:

> Byung-Hee HWANG wrote:
>
>>>>>>> I have a mail on that system, incal@dataswamp.org and
>>>>>>> it works to mail there, but, in order to check it out
>>>>>>> I do first ssh and then use the mail(1) utility.
>>>>>>
>>>>>> And how does mail access the mailbox?
>>>>>
>>>>> I don't know, it reads, in my case, /var/mail/incal ?
>>>>
>>>> Maybe the backend `nnmbox' ...
>>>>
>>>> (info "(gnus) Unix Mail Box")
>>>
>>> ... and then?
>>
>> Otherwise you do forward to zoho.eu, then you could check
>> all emails at one account <moasenwood@zoho.eu>.
>
> Yeah but what I would like is incal@dataswamp.org :(
>
> Actually that already works, to /var/mail/incal, but I can't
> read or send with Gnus.

Actually i do not know your server <dataswamp.org>. Perhaps, would you
do check here?
https://www.gnu.org/software/emacs/manual/html_node/gnus/Using-IMAP.html

For example, mine is simple:
#+begin_src elisp
(add-to-list 'gnus-secondary-select-methods
             '(nnimap "gmail"
                      (nnimap-address "imap.gmail.com")
                      (nnimap-server-port "imaps")
                      (nnimap-stream ssl)))
#+end_src

>> Honestly, however, fowarding is not easy nowdays.
>
> Okay?

Ho-Ho-Ho~ It seems like, at once, you did try in the past...

Sincerely, Gnus fan Byung-Hee

-- 
^고맙습니다 _和合團結_ 감사합니다_^))//


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-11  3:47                 ` Byung-Hee HWANG
@ 2022-04-11  4:03                   ` Byung-Hee HWANG
  2022-04-11 22:55                     ` Bob Newell
  2022-04-12  6:00                   ` Emanuel Berg
  1 sibling, 1 reply; 57+ messages in thread
From: Byung-Hee HWANG @ 2022-04-11  4:03 UTC (permalink / raw)
  To: ding

[...sorry it just slipped my mind...]

> #+begin_src elisp
> (add-to-list 'gnus-secondary-select-methods
>              '(nnimap "gmail"
>                       (nnimap-address "imap.gmail.com")
>                       (nnimap-server-port "imaps")
>                       (nnimap-stream ssl)))
> #+end_src

If *absolutely* Google goes with 'Oauth2', then i have to use getmail.
Until then, i'll keep these setup with nnimap.

Sincerely, Gnus fan Byung-Hee

[^^^] getmail: <https://pyropus.ca./software/getmail/>

-- 
^고맙습니다 _和合團結_ 감사합니다_^))//


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-11  4:03                   ` Byung-Hee HWANG
@ 2022-04-11 22:55                     ` Bob Newell
  2022-04-12  2:18                       ` Byung-Hee HWANG
  2022-04-12  8:30                       ` Eric S Fraga
  0 siblings, 2 replies; 57+ messages in thread
From: Bob Newell @ 2022-04-11 22:55 UTC (permalink / raw)
  To: ding

> If *absolutely* Google goes with 'Oauth2', then i have to use getmail.
> Until then, i'll keep these setup with nnimap.

Supposedly you can make gmail work with gnus and oauth2 via
nnimap, but I haven't had the courage to try to implement this
as yet.

Maybe someone who knows more about it or who has it working
can respond?

-- 
Bob Newell
Honolulu, Hawai`i

- Via GNU/Linux/Emacs/Gnus/BBDB


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-11 22:55                     ` Bob Newell
@ 2022-04-12  2:18                       ` Byung-Hee HWANG
  2022-04-12  8:30                       ` Eric S Fraga
  1 sibling, 0 replies; 57+ messages in thread
From: Byung-Hee HWANG @ 2022-04-12  2:18 UTC (permalink / raw)
  To: ding

Dear Bob,

Bob Newell <bobnewell@bobnewell.net> writes:

>> If *absolutely* Google goes with 'Oauth2', then i have to use
>> getmail.
>> Until then, i'll keep these setup with nnimap.
>
> Supposedly you can make gmail work with gnus and oauth2 via
> nnimap, but I haven't had the courage to try to implement this
> as yet.
>
> Maybe someone who knows more about it or who has it working
> can respond?

Yes, i'll wait for the good news!

Thanks ^^^

Sincerely, Gnus fan Byung-Hee

-- 
^고맙습니다 _地平天成_ 감사합니다_^))//


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-11  3:47                 ` Byung-Hee HWANG
  2022-04-11  4:03                   ` Byung-Hee HWANG
@ 2022-04-12  6:00                   ` Emanuel Berg
  2022-04-12  6:34                     ` Emanuel Berg
  2022-04-19 23:53                     ` Emanuel Berg
  1 sibling, 2 replies; 57+ messages in thread
From: Emanuel Berg @ 2022-04-12  6:00 UTC (permalink / raw)
  To: ding

Byung-Hee HWANG wrote:

>>>>>>>> I have a mail on that system, incal@dataswamp.org and
>>>>>>>> it works to mail there, but, in order to check it out
>>>>>>>> I do first ssh and then use the mail(1) utility.
>>>>>>>
>>>>>>> And how does mail access the mailbox?
>>>>>>
>>>>>> I don't know, it reads, in my case, /var/mail/incal ?
>>>>>
>>>>> Maybe the backend `nnmbox' ...
>>>>>
>>>>> (info "(gnus) Unix Mail Box")
>>>>
>>>> ... and then?
>>>
>>> Otherwise you do forward to zoho.eu, then you could check
>>> all emails at one account <moasenwood@zoho.eu>.
>>
>> Yeah but what I would like is incal@dataswamp.org :(
>>
>> Actually that already works, to /var/mail/incal, but I can't
>> read or send with Gnus.
>
> Actually i do not know your server <dataswamp.org>. Perhaps,
> would you do check here?
> https://www.gnu.org/software/emacs/manual/html_node/gnus/Using-IMAP.html

IIUC the server doesn't offer IMAP directly so one must use
.forward, fdm(1), and dovecot(1) to create a virtual
environment for the system mail that one can access with Gnus
thru the common IMAP backend/interface ...

But the mails don't end up in ~/Maildir :(

PS. Check out above BTW, 8 levels of citation B)

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-12  6:00                   ` Emanuel Berg
@ 2022-04-12  6:34                     ` Emanuel Berg
  2022-04-19 23:53                     ` Emanuel Berg
  1 sibling, 0 replies; 57+ messages in thread
From: Emanuel Berg @ 2022-04-12  6:34 UTC (permalink / raw)
  To: ding

> PS. Check out above BTW, 8 levels of citation B)

Or 8) I mean :)

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-11 22:55                     ` Bob Newell
  2022-04-12  2:18                       ` Byung-Hee HWANG
@ 2022-04-12  8:30                       ` Eric S Fraga
  1 sibling, 0 replies; 57+ messages in thread
From: Eric S Fraga @ 2022-04-12  8:30 UTC (permalink / raw)
  To: ding

On Monday, 11 Apr 2022 at 12:55, Bob Newell wrote:
> Maybe someone who knows more about it or who has it working
> can respond?

When my organization moved to two-factor authentication with Exchange,
the easiest solution (for me) was to use davmail to retrieve emails from
the server and act as a local mail server.  It was very easy; I don't
know, however, what the support for gmail might be but it could be worth
checking.

-- 
Eric S Fraga with org 9.5.2 in Emacs 29.0.50 on Debian 11.2



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-12  6:00                   ` Emanuel Berg
  2022-04-12  6:34                     ` Emanuel Berg
@ 2022-04-19 23:53                     ` Emanuel Berg
  2022-04-20  0:11                       ` Emanuel Berg
  1 sibling, 1 reply; 57+ messages in thread
From: Emanuel Berg @ 2022-04-19 23:53 UTC (permalink / raw)
  To: ding

> But the mails don't end up in ~/Maildir :(

Now they do!

.forward is

  | /usr/local/bin/fdm -m -a stdin fetch

~/.fdm.conf is

  account "stdin" disabled stdin
  action "inbox" maildir "/home/incal/Maildir/"
  match all action "inbox"

That first line was missing!

Also the dir ~/Maildir and its subdirs cur, new and tmp should
have permissions 700, not 755!

So now all this is done, will try to fetch it from Gnus
later Gw!

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-19 23:53                     ` Emanuel Berg
@ 2022-04-20  0:11                       ` Emanuel Berg
  2022-04-21 12:38                         ` Byung-Hee HWANG
  0 siblings, 1 reply; 57+ messages in thread
From: Emanuel Berg @ 2022-04-20  0:11 UTC (permalink / raw)
  To: ding

> So now all this is done, will try to fetch it from Gnus
> later Gw!

Works! \o/

(Below, only the nnimap list list item is relevant to
this thread.)

(setq gnus-secondary-select-methods
      '((nntp "nntp.aioe.org")
        (nnimap "Mail"
                (nnimap-stream shell)
                (nnimap-shell-program
                 "ssh incal@dataswamp.org /usr/local/libexec/dovecot/imap -o mail_location=maildir:~/Maildir/:LAYOUT=fs"))
        (nnml "") ))

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-07  9:31 ` Christian Barthel
  2022-04-07 10:57   ` Emanuel Berg
  2022-04-09 23:23   ` Emanuel Berg
@ 2022-04-21  1:42   ` Emanuel Berg
  2022-04-21  2:52     ` Emanuel Berg
  2022-04-21  2:54     ` Emanuel Berg
  2 siblings, 2 replies; 57+ messages in thread
From: Emanuel Berg @ 2022-04-21  1:42 UTC (permalink / raw)
  To: ding

Christian Barthel wrote:

> And then, you have to setup SMTP to send emails.

Here is where I am now, the server is smtp.dataswamp.org

Port 465? Or 587?

I set it up minimally but it didn't work with either, are
there some extras to it?

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-21  1:42   ` Emanuel Berg
@ 2022-04-21  2:52     ` Emanuel Berg
  2022-04-21  2:54     ` Emanuel Berg
  1 sibling, 0 replies; 57+ messages in thread
From: Emanuel Berg @ 2022-04-21  2:52 UTC (permalink / raw)
  To: ding

>> And then, you have to setup SMTP to send emails.
>
> Here is where I am now, the server is smtp.dataswamp.org
>
> Port 465? Or 587?
>
> I set it up minimally but it didn't work with either, are
> there some extras to it?

Maybe a SSH-tunnel (port forwarding) since the system is 2FA
to begin with ...

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-21  1:42   ` Emanuel Berg
  2022-04-21  2:52     ` Emanuel Berg
@ 2022-04-21  2:54     ` Emanuel Berg
  1 sibling, 0 replies; 57+ messages in thread
From: Emanuel Berg @ 2022-04-21  2:54 UTC (permalink / raw)
  To: ding

> Here is where I am now, the server is smtp.dataswamp.org
>
> Port 465? Or 587?
>
> I set it up minimally but it didn't work with either, are
> there some extras to it?

Maybe a SSH-tunnel (port forwarding) since the system is 2FA
to begin with ...

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-20  0:11                       ` Emanuel Berg
@ 2022-04-21 12:38                         ` Byung-Hee HWANG
  2022-04-21 13:16                           ` Emanuel Berg
  0 siblings, 1 reply; 57+ messages in thread
From: Byung-Hee HWANG @ 2022-04-21 12:38 UTC (permalink / raw)
  To: ding

Emanuel Berg <moasenwood@zoho.eu> writes:

>> So now all this is done, will try to fetch it from Gnus
>> later Gw!
>
> Works! \o/
>
> (Below, only the nnimap list list item is relevant to
> this thread.)
>
> (setq gnus-secondary-select-methods
>       '((nntp "nntp.aioe.org")
>         (nnimap "Mail"
>                 (nnimap-stream shell)
>                 (nnimap-shell-program
>                  "ssh incal@dataswamp.org /usr/local/libexec/dovecot/imap -o mail_location=maildir:~/Maildir/:LAYOUT=fs"))
>         (nnml "") ))

Oh cool! Would you please screenshots?

Sincerely, Gnus fan Byung-Hee

-- 
^고맙습니다 _布德天下_ 감사합니다_^))//


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-21 12:38                         ` Byung-Hee HWANG
@ 2022-04-21 13:16                           ` Emanuel Berg
  2022-04-21 13:30                             ` Byung-Hee HWANG
  0 siblings, 1 reply; 57+ messages in thread
From: Emanuel Berg @ 2022-04-21 13:16 UTC (permalink / raw)
  To: ding

[-- Attachment #1: Type: text/plain, Size: 475 bytes --]

Byung-Hee HWANG wrote:

>> (setq gnus-secondary-select-methods
>>     '((nntp "nntp.aioe.org")
>>       (nnimap "Mail"
>>               (nnimap-stream shell)
>>               (nnimap-shell-program
>>                "ssh incal@dataswamp.org /usr/local/libexec/dovecot/imap -o mail_location=maildir:~/Maildir/:LAYOUT=fs"))
>>       (nnml "") ))
>
> Oh cool! Would you please screenshots?

Do it today - in a different way!

https://dataswamp.org/~incal/figures/gnus/hwang.png


[-- Attachment #2: hwang.png --]
[-- Type: image/png, Size: 6699 bytes --]

[-- Attachment #3: Type: text/plain, Size: 61 bytes --]


-- 
underground experts united
https://dataswamp.org/~incal

^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-21 13:16                           ` Emanuel Berg
@ 2022-04-21 13:30                             ` Byung-Hee HWANG
  2022-04-21 13:41                               ` Emanuel Berg
  2022-04-27 20:15                               ` Emanuel Berg
  0 siblings, 2 replies; 57+ messages in thread
From: Byung-Hee HWANG @ 2022-04-21 13:30 UTC (permalink / raw)
  To: ding

Emanuel Berg <moasenwood@zoho.eu> writes:

> Byung-Hee HWANG wrote:
>
>>> (setq gnus-secondary-select-methods
>>>     '((nntp "nntp.aioe.org")
>>>       (nnimap "Mail"
>>>               (nnimap-stream shell)
>>>               (nnimap-shell-program
>>>                "ssh incal@dataswamp.org /usr/local/libexec/dovecot/imap -o mail_location=maildir:~/Maildir/:LAYOUT=fs"))
>>>       (nnml "") ))
>>
>> Oh cool! Would you please screenshots?
>
> Do it today - in a different way!
>
> https://dataswamp.org/~incal/figures/gnus/hwang.png

Very good Ha-Ha! So you have 7 emails in <<dataswamp.org>>!

Thanks for sharing Emanuel ^^^

Sincerely, Gnus fan Byung-Hee

-- 
^고맙습니다 _布德天下_ 감사합니다_^))//


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-21 13:30                             ` Byung-Hee HWANG
@ 2022-04-21 13:41                               ` Emanuel Berg
  2022-04-27 20:15                               ` Emanuel Berg
  1 sibling, 0 replies; 57+ messages in thread
From: Emanuel Berg @ 2022-04-21 13:41 UTC (permalink / raw)
  To: ding

Byung-Hee HWANG wrote:

>> https://dataswamp.org/~incal/figures/gnus/hwang.png
>
> Very good Ha-Ha! So you have 7 emails in <<dataswamp.org>>!

Private investigator!!

> Thanks for sharing Emanuel ^^^

:)

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-21 13:30                             ` Byung-Hee HWANG
  2022-04-21 13:41                               ` Emanuel Berg
@ 2022-04-27 20:15                               ` Emanuel Berg
  2022-04-27 20:27                                 ` Emanuel Berg
  2022-04-28  3:44                                 ` Byung-Hee HWANG
  1 sibling, 2 replies; 57+ messages in thread
From: Emanuel Berg @ 2022-04-27 20:15 UTC (permalink / raw)
  To: ding

With `smtpmail-smtp-server' "localhost" and
`smtpmail-smtp-service' 2525, and this command

and this command

  ssh -N -L 127.0.0.1:2525:127.0.0.1:25 dataswamp.org

it says

  network-stream-open-starttls: Wrong type argument: processp, nil

Anyone knows what that means?

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-27 20:15                               ` Emanuel Berg
@ 2022-04-27 20:27                                 ` Emanuel Berg
  2022-04-28  3:44                                 ` Byung-Hee HWANG
  1 sibling, 0 replies; 57+ messages in thread
From: Emanuel Berg @ 2022-04-27 20:27 UTC (permalink / raw)
  To: ding

> With `smtpmail-smtp-server' "localhost" and
> `smtpmail-smtp-service' 2525, and this command
>
> and this command
>
>   ssh -N -L 127.0.0.1:2525:127.0.0.1:25 dataswamp.org
>
> it says
>
>   network-stream-open-starttls: Wrong type argument: processp, nil
>
> Anyone knows what that means?

Indeed, no TLS needed, if one sets that to nil it works.
Which is the default BTW :)

(setq
  smtpmail-smtp-server "localhost"
  smtpmail-smtp-service 2525
  smtpmail-stream-type nil
  user-mail-address    (format "%s@%s" user-login-name "dataswamp.org")
)

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-27 20:15                               ` Emanuel Berg
  2022-04-27 20:27                                 ` Emanuel Berg
@ 2022-04-28  3:44                                 ` Byung-Hee HWANG
  2022-05-03  2:36                                   ` Emanuel Berg
  1 sibling, 1 reply; 57+ messages in thread
From: Byung-Hee HWANG @ 2022-04-28  3:44 UTC (permalink / raw)
  To: ding

Hellow Emanuel,

Emanuel Berg <moasenwood@zoho.eu> writes:

> (... thanks ...)
>   ssh -N -L 127.0.0.1:2525:127.0.0.1:25 dataswamp.org
>

You first read again: (3 times good!)
<https://www.rackaid.com/blog/spam-ssh-tunnel/>

This is my test:
#+begin_src text (shell command output)
soyeomul@yw-1130:~/bin$ ./gt.py
인터넷 연결 OK!
포트 2000 무사히 열었습니다^^^ ===> PID: 6881
soyeomul@yw-1130:~/bin$ telnet localhost 2000
Trying ::1...
Connected to localhost.
Escape character is '^]'.
220 yw-0919.doraji.xyz ESMTP Postfix (Ubuntu/Google-Compute-Engine)
ehlo delta
250-yw-0919.doraji.xyz
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-STARTTLS
250-ENHANCEDSTATUSCODES
250-8BITMIME
250-DSN
250 SMTPUTF8
quit
221 2.0.0 Bye
Connection closed by foreign host.
soyeomul@yw-1130:~/bin$ 
#+end_src

And i'm using X-Message-SMTP-Method like as:
#+begin_src emacs-lisp
(...something...)
("X-Message-SMTP-Method" "smtp localhost 2000")
(address "soyeomul@yw.doraji.xyz")
(...something...)
#+end_src

Sincerely, Gnus fan Byung-Hee

-- 
^고맙습니다 _布德天下_ 감사합니다_^))//


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-04-28  3:44                                 ` Byung-Hee HWANG
@ 2022-05-03  2:36                                   ` Emanuel Berg
  2022-05-03  6:36                                     ` Byung-Hee HWANG
  2022-05-04 11:50                                     ` expiring in nnselect groups not saved Erik Colson
  0 siblings, 2 replies; 57+ messages in thread
From: Emanuel Berg @ 2022-05-03  2:36 UTC (permalink / raw)
  To: ding

Byung-Hee HWANG wrote:

>> ssh -N -L 127.0.0.1:2525:127.0.0.1:25 dataswamp.org
>>
>
> You first read again: (3 times good!)

?

> <https://www.rackaid.com/blog/spam-ssh-tunnel/>

Hm ... OK, I told the admin about on IRC just now, he probably
knows about it tho.

> This is my test:
>
> #+begin_src text (shell command output)
> soyeomul@yw-1130:~/bin$ ./gt.py [...]

?

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-05-03  2:36                                   ` Emanuel Berg
@ 2022-05-03  6:36                                     ` Byung-Hee HWANG
  2022-05-03  7:01                                       ` Emanuel Berg
  2022-05-04 11:50                                     ` expiring in nnselect groups not saved Erik Colson
  1 sibling, 1 reply; 57+ messages in thread
From: Byung-Hee HWANG @ 2022-05-03  6:36 UTC (permalink / raw)
  To: ding


>> soyeomul@yw-1130:~/bin$ ./gt.py [...]
>
> ?

That was my script. No important.

Thanks,

Sincerely, Gnus fan Byung-Hee

-- 
^고맙습니다 _布德天下_ 감사합니다_^))//

^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-05-03  6:36                                     ` Byung-Hee HWANG
@ 2022-05-03  7:01                                       ` Emanuel Berg
  2022-05-03  7:17                                         ` Byung-Hee HWANG
  0 siblings, 1 reply; 57+ messages in thread
From: Emanuel Berg @ 2022-05-03  7:01 UTC (permalink / raw)
  To: ding

Byung-Hee HWANG wrote:

>>> soyeomul@yw-1130:~/bin$ ./gt.py [...]
>>>
>>
>> ?
>
> That was my script. No important.

Don't say that but ... do you have a link to the
actual script?

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-05-03  7:01                                       ` Emanuel Berg
@ 2022-05-03  7:17                                         ` Byung-Hee HWANG
  2022-05-04  0:11                                           ` Emanuel Berg
  0 siblings, 1 reply; 57+ messages in thread
From: Byung-Hee HWANG @ 2022-05-03  7:17 UTC (permalink / raw)
  To: ding

> do you have a link to the actual script?

<https://gitlab.com/soyeomul/Gnus/-/raw/karma/gt.py>

It's not general purpose. However it is useful only to me.
Tested by my chromebook, Ubuntu 18.04 LTS and Debian 11 Bullseye.

Thanks,

Sincerely, Gnus fan Byung-Hee

-- 
^고맙습니다 _布德天下_ 감사합니다_^))//


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
  2022-05-03  7:17                                         ` Byung-Hee HWANG
@ 2022-05-04  0:11                                           ` Emanuel Berg
  0 siblings, 0 replies; 57+ messages in thread
From: Emanuel Berg @ 2022-05-04  0:11 UTC (permalink / raw)
  To: ding

Byung-Hee HWANG wrote:

>> do you have a link to the actual script?
>
> https://gitlab.com/soyeomul/Gnus/-/raw/karma/gt.py
>
> It's not general purpose. However it is useful only to me.

Indeed, since so many of those chars aren't even displayable
here ...

ASCII and the old Anglo-American is a good idea in computing -
that not everyone has to follow.

-- 
underground experts united
https://dataswamp.org/~incal



^ permalink raw reply	[flat|nested] 57+ messages in thread

* expiring in nnselect groups not saved
  2022-05-03  2:36                                   ` Emanuel Berg
  2022-05-03  6:36                                     ` Byung-Hee HWANG
@ 2022-05-04 11:50                                     ` Erik Colson
  2022-05-04 17:01                                       ` Eric Abrahamsen
  1 sibling, 1 reply; 57+ messages in thread
From: Erik Colson @ 2022-05-04 11:50 UTC (permalink / raw)
  To: ding

Hi,

When I issue a search over multiple groups, gnus will show a nnselect
summary buffer.  When I mark articles ready for Expiry, quit and return,
the Expire mark is lost.

How can I save the mark ?

best
-- 
erik colson


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: expiring in nnselect groups not saved
  2022-05-04 11:50                                     ` expiring in nnselect groups not saved Erik Colson
@ 2022-05-04 17:01                                       ` Eric Abrahamsen
  2022-05-04 21:47                                         ` Erik Colson
  0 siblings, 1 reply; 57+ messages in thread
From: Eric Abrahamsen @ 2022-05-04 17:01 UTC (permalink / raw)
  To: ding

Erik Colson <eco@ecocode.net> writes:

> Hi,
>
> When I issue a search over multiple groups, gnus will show a nnselect
> summary buffer.  When I mark articles ready for Expiry, quit and return,
> the Expire mark is lost.
>
> How can I save the mark ?

Andy made this possible in a commit a couple of months ago (also
requires setting `nnselect-allow-ephemeral-expiry' to a non-nil value),
so unless you're running from master (which isn't a terrible idea), you
might not have this yet.



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: expiring in nnselect groups not saved
  2022-05-04 17:01                                       ` Eric Abrahamsen
@ 2022-05-04 21:47                                         ` Erik Colson
  2022-05-05  0:39                                           ` Andrew Cohen
  0 siblings, 1 reply; 57+ messages in thread
From: Erik Colson @ 2022-05-04 21:47 UTC (permalink / raw)
  To: ding

Eric Abrahamsen <eric@ericabrahamsen.net> writes:

> Andy made this possible in a commit a couple of months ago (also
> requires setting `nnselect-allow-ephemeral-expiry' to a non-nil value),
> so unless you're running from master (which isn't a terrible idea), you
> might not have this yet.

Thanks for the info, it solves another problem I had ;)

I have that variable and now messages get expired when I leave an
nnselect group.

But what I asked for is saving the expiry marks I add while in a
nnselect group, which still doesn't seem to work with that variable set
to t.

best
-- 
erik colson


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: expiring in nnselect groups not saved
  2022-05-04 21:47                                         ` Erik Colson
@ 2022-05-05  0:39                                           ` Andrew Cohen
  2022-05-05  0:48                                             ` Andrew Cohen
  2022-05-05 10:10                                             ` Erik Colson
  0 siblings, 2 replies; 57+ messages in thread
From: Andrew Cohen @ 2022-05-05  0:39 UTC (permalink / raw)
  To: ding

>>>>> "EC" == Erik Colson <eco@ecocode.net> writes:

    EC> Eric Abrahamsen <eric@ericabrahamsen.net> writes:
    >> Andy made this possible in a commit a couple of months ago (also
    >> requires setting `nnselect-allow-ephemeral-expiry' to a non-nil
    >> value), so unless you're running from master (which isn't a
    >> terrible idea), you might not have this yet.

    EC> Thanks for the info, it solves another problem I had ;)

    EC> I have that variable and now messages get expired when I leave
    EC> an nnselect group.

    EC> But what I asked for is saving the expiry marks I add while in a
    EC> nnselect group, which still doesn't seem to work with that
    EC> variable set to t.

Then this would be a bug :) I don't have a lot of time at the moment,
but when I do I'll take a look. If you are comfortable with debugging
the relevant code is in nnselect-push-info. There is an iterative loop
over gnus-article-mark-lists (which includes the expirable mark) which
should be doing the work.

Does it work with a single group (if its specific to multiple groups
that would be relevant info)?

-- 
Andrew Cohen



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: expiring in nnselect groups not saved
  2022-05-05  0:39                                           ` Andrew Cohen
@ 2022-05-05  0:48                                             ` Andrew Cohen
  2022-05-05  2:07                                               ` Andrew Cohen
  2022-05-05 10:10                                             ` Erik Colson
  1 sibling, 1 reply; 57+ messages in thread
From: Andrew Cohen @ 2022-05-05  0:48 UTC (permalink / raw)
  To: ding

>>>>> "AC" == Andrew Cohen <acohen@ust.hk> writes:

[...]

    AC> Then this would be a bug :)

And I just tried it and found the expirable mark was properly set in the
underlying groups.  (I did a search in multiple groups, set the
expirable mark in the resulting nnselect group, entered the originating
group and saw the expirable mark properly set).

So we will have to do some debugging on your end to find out why it
isn't working.

I have some updates in my code that I have been using for some time and
haven't had a chance to push to master. Probably not worth debugging
until I get around to it---no point in debugging different code :)

-- 
Andrew Cohen



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: expiring in nnselect groups not saved
  2022-05-05  0:48                                             ` Andrew Cohen
@ 2022-05-05  2:07                                               ` Andrew Cohen
  0 siblings, 0 replies; 57+ messages in thread
From: Andrew Cohen @ 2022-05-05  2:07 UTC (permalink / raw)
  To: ding

>>>>> "AC" == Andrew Cohen <acohen@ust.hk> writes:

>>>>> "AC" == Andrew Cohen <acohen@ust.hk> writes:
    AC> [...]

    AC> Then this would be a bug :)

[...]

    AC> I have some updates in my code that I have been using for some
    AC> time and haven't had a chance to push to master. Probably not
    AC> worth debugging until I get around to it---no point in debugging
    AC> different code :)

And I take this back. The code updates I have in my queue shouldn't be
relevant. As long as you are using the current master we should have the
same code. Debug away!

Note you can use (assoc 'expire (gnus-info-marks (gnus-get-info
"groupname"))) from the scratch buffer to see the list of articles
with the expirable mark---no need to enter the group. 

-- 
Andrew Cohen



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: expiring in nnselect groups not saved
  2022-05-05  0:39                                           ` Andrew Cohen
  2022-05-05  0:48                                             ` Andrew Cohen
@ 2022-05-05 10:10                                             ` Erik Colson
  2022-05-05 10:48                                               ` Erik Colson
  1 sibling, 1 reply; 57+ messages in thread
From: Erik Colson @ 2022-05-05 10:10 UTC (permalink / raw)
  To: Andrew Cohen; +Cc: ding

Andrew Cohen <acohen@ust.hk> writes:

> Does it work with a single group (if its specific to multiple groups
> that would be relevant info)?

nope, same behaviour.  although I thought it did but after testing again
it did not.
-- 
erik colson


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: expiring in nnselect groups not saved
  2022-05-05 10:10                                             ` Erik Colson
@ 2022-05-05 10:48                                               ` Erik Colson
  2022-05-05 11:09                                                 ` Erik Colson
  0 siblings, 1 reply; 57+ messages in thread
From: Erik Colson @ 2022-05-05 10:48 UTC (permalink / raw)
  To: Andrew Cohen; +Cc: ding

hmmm... so things are evolving :)

sometimes it works, sometimes it doesn't.  I think that when it doesn't
work, the nnselect buffer is **not** closed after hitting 'q' and seeing
the message 'Expiring articles...'.  When it works, the buffer is closed
and removed.

I can't seem to figure why the buffer isn't closed :(
-- 
erik colson


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: expiring in nnselect groups not saved
  2022-05-05 10:48                                               ` Erik Colson
@ 2022-05-05 11:09                                                 ` Erik Colson
  2022-05-05 11:21                                                   ` Erik Colson
  0 siblings, 1 reply; 57+ messages in thread
From: Erik Colson @ 2022-05-05 11:09 UTC (permalink / raw)
  To: Andrew Cohen; +Cc: ding

I was wrong.  It just works in some groups and doesn't in others.

Never seem to work for these:
     1274/ 2205: FASTMAIL/BEAVER-Inbox  (level 1)
     1440/ 2810: FASTMAIL/Inbox  (level 1)

Always seem to work in this one:
     27/ 1205:*CODEPM/ECOCODE/list/Gnus-ding  (level 1)

All groups are on the same backend.
These are group parameters:
(gnus-group-get-parameter "CODEPM/ECOCODE/list/Gnus-ding")
  ((modseq . "127") (uidvalidity . "1651497864") (active 1 . 1202) (permanent-flags %Answered %Flagged %Deleted %Seen %Draft gnus-expire %*) (to-list . "ding@gnus.org"))

(gnus-group-get-parameter "FASTMAIL/BEAVER-Inbox")
  ((modseq . "278") (uidvalidity . "1651497469") (active 1 . 2205) (permanent-flags %Answered %Flagged %Deleted %Seen %Draft gnus-expire %*))


I loose it here :/
-- 
erik colson


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: expiring in nnselect groups not saved
  2022-05-05 11:09                                                 ` Erik Colson
@ 2022-05-05 11:21                                                   ` Erik Colson
  2022-05-05 12:20                                                     ` Erik Colson
  0 siblings, 1 reply; 57+ messages in thread
From: Erik Colson @ 2022-05-05 11:21 UTC (permalink / raw)
  To: Andrew Cohen; +Cc: ding

Erik Colson <eco@ecocode.net> writes:

> I was wrong.  It just works in some groups and doesn't in others.
> 
> Never seem to work for these:
>      1274/ 2205: FASTMAIL/BEAVER-Inbox  (level 1)
>      1440/ 2810: FASTMAIL/Inbox  (level 1)
> 
> Always seem to work in this one:
>      27/ 1205:*CODEPM/ECOCODE/list/Gnus-ding  (level 1)
 
Now I tested getting those groups in one nnselect search buffer.  Marked
messages from those 3 groups as expired.  Only the messages in the
Gnus-ding group save the mark !
-- 
erik colson


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: expiring in nnselect groups not saved
  2022-05-05 11:21                                                   ` Erik Colson
@ 2022-05-05 12:20                                                     ` Erik Colson
  2022-05-05 20:59                                                       ` Erik Colson
  0 siblings, 1 reply; 57+ messages in thread
From: Erik Colson @ 2022-05-05 12:20 UTC (permalink / raw)
  To: Andrew Cohen; +Cc: ding

Hi

I am still not out of this.  I tried `gnus-group-clear-data` on one of
the groups it doesn't work.  All marks were reset, but the issue
remains.
-- 
erik colson


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: expiring in nnselect groups not saved
  2022-05-05 12:20                                                     ` Erik Colson
@ 2022-05-05 20:59                                                       ` Erik Colson
  2022-05-06  0:49                                                         ` Andrew Cohen
  0 siblings, 1 reply; 57+ messages in thread
From: Erik Colson @ 2022-05-05 20:59 UTC (permalink / raw)
  To: Andrew Cohen; +Cc: ding

Hi,

I think I got something ...
When I create an "permanent" nnselect group with Gg, all expiry flags
get saved in all groups.  When I create an ephemeral search group with
GG they only get saved in one group, which I cannot seem to figure why.

So permanent nnselect groups work, ephemeral don't...

hope this helps
-- 
erik colson


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: expiring in nnselect groups not saved
  2022-05-05 20:59                                                       ` Erik Colson
@ 2022-05-06  0:49                                                         ` Andrew Cohen
  2022-05-06 15:42                                                           ` Erik Colson
  0 siblings, 1 reply; 57+ messages in thread
From: Andrew Cohen @ 2022-05-06  0:49 UTC (permalink / raw)
  To: ding

>>>>> "EC" == Erik Colson <eco@ecocode.net> writes:

    EC> Hi, I think I got something ...  When I create an "permanent"
    EC> nnselect group with Gg, all expiry flags get saved in all
    EC> groups.  When I create an ephemeral search group with GG they
    EC> only get saved in one group, which I cannot seem to figure why.

OK, I think I found the bug. There is ancient code (from 10 years ago
when nnir groups weren't supposed to do any expiry) which special cases
expirable marks to prevent unexpected expiry. This code is
obsolete and should be removed, I think. But it's from so long ago I
hardly remember why I added it. Erik, can you test this?

Replace the current function 'nnselect-request-update-mark with the one below:

(deffoo nnselect-request-update-mark (_group article mark)
  (let* ((artgroup (nnselect-article-group article))
	 (artnumber (nnselect-article-number article))
	 (gmark (gnus-request-update-mark artgroup artnumber mark)))
    gmark))


-- 
Andrew Cohen



^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: expiring in nnselect groups not saved
  2022-05-06  0:49                                                         ` Andrew Cohen
@ 2022-05-06 15:42                                                           ` Erik Colson
  2022-05-06 16:27                                                             ` Erik Colson
  0 siblings, 1 reply; 57+ messages in thread
From: Erik Colson @ 2022-05-06 15:42 UTC (permalink / raw)
  To: Andrew Cohen; +Cc: ding

Andrew Cohen <acohen@ust.hk> writes:

> Replace the current function 'nnselect-request-update-mark with the one below:
>
> (deffoo nnselect-request-update-mark (_group article mark)
>   (let* ((artgroup (nnselect-article-group article))
> 	 (artnumber (nnselect-article-number article))
> 	 (gmark (gnus-request-update-mark artgroup artnumber mark)))
>     gmark))

Hi Andrew,

I ran the code above from a scratch buffer and then tried again.  The
issue is still present.  However I am not sure running the code above
does replace the function.  If not, can you tell me how to do the
replacement ?  (preferably without replacing it in nnselect.el)

thx
-- 
erik colson


^ permalink raw reply	[flat|nested] 57+ messages in thread

* Re: expiring in nnselect groups not saved
  2022-05-06 15:42                                                           ` Erik Colson
@ 2022-05-06 16:27                                                             ` Erik Colson
  0 siblings, 0 replies; 57+ messages in thread
From: Erik Colson @ 2022-05-06 16:27 UTC (permalink / raw)
  To: Andrew Cohen; +Cc: ding

Hi Andrew!

BTW I am on fedora 35 and installed emacs through copr

Version      : 29.0.50
Release      : 1.20220329.git2b5ea36.fc35
From repo    : copr:copr.fedorainfracloud.org:deathwish:emacs-pgtk-nativecomp

So my version is dated 29 March.  Is it too outdated for the changes you
coded ?
-- 
erik colson


^ permalink raw reply	[flat|nested] 57+ messages in thread

end of thread, other threads:[~2022-05-06 16:27 UTC | newest]

Thread overview: 57+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-07  1:17 set up Gnus to work with a remote system mailserver (with Dovecot?) Emanuel Berg
2022-04-07  2:34 ` Byung-Hee HWANG
2022-04-07  3:08   ` Emanuel Berg
2022-04-07  7:47     ` Andreas Schwab
2022-04-07  8:07       ` Emanuel Berg
2022-04-07  8:12         ` Emanuel Berg
2022-04-07  8:27           ` Emanuel Berg
2022-04-10 11:47             ` Byung-Hee HWANG
2022-04-10 13:13               ` Emanuel Berg
2022-04-11  3:47                 ` Byung-Hee HWANG
2022-04-11  4:03                   ` Byung-Hee HWANG
2022-04-11 22:55                     ` Bob Newell
2022-04-12  2:18                       ` Byung-Hee HWANG
2022-04-12  8:30                       ` Eric S Fraga
2022-04-12  6:00                   ` Emanuel Berg
2022-04-12  6:34                     ` Emanuel Berg
2022-04-19 23:53                     ` Emanuel Berg
2022-04-20  0:11                       ` Emanuel Berg
2022-04-21 12:38                         ` Byung-Hee HWANG
2022-04-21 13:16                           ` Emanuel Berg
2022-04-21 13:30                             ` Byung-Hee HWANG
2022-04-21 13:41                               ` Emanuel Berg
2022-04-27 20:15                               ` Emanuel Berg
2022-04-27 20:27                                 ` Emanuel Berg
2022-04-28  3:44                                 ` Byung-Hee HWANG
2022-05-03  2:36                                   ` Emanuel Berg
2022-05-03  6:36                                     ` Byung-Hee HWANG
2022-05-03  7:01                                       ` Emanuel Berg
2022-05-03  7:17                                         ` Byung-Hee HWANG
2022-05-04  0:11                                           ` Emanuel Berg
2022-05-04 11:50                                     ` expiring in nnselect groups not saved Erik Colson
2022-05-04 17:01                                       ` Eric Abrahamsen
2022-05-04 21:47                                         ` Erik Colson
2022-05-05  0:39                                           ` Andrew Cohen
2022-05-05  0:48                                             ` Andrew Cohen
2022-05-05  2:07                                               ` Andrew Cohen
2022-05-05 10:10                                             ` Erik Colson
2022-05-05 10:48                                               ` Erik Colson
2022-05-05 11:09                                                 ` Erik Colson
2022-05-05 11:21                                                   ` Erik Colson
2022-05-05 12:20                                                     ` Erik Colson
2022-05-05 20:59                                                       ` Erik Colson
2022-05-06  0:49                                                         ` Andrew Cohen
2022-05-06 15:42                                                           ` Erik Colson
2022-05-06 16:27                                                             ` Erik Colson
2022-04-07  8:51 ` set up Gnus to work with a remote system mailserver (with Dovecot?) Uwe Brauer
2022-04-07  8:58   ` Emanuel Berg
2022-04-07 10:28   ` Eric S Fraga
2022-04-07 16:43     ` Russ Allbery
2022-04-08 10:03       ` Eric S Fraga
2022-04-08 11:59         ` Emanuel Berg
2022-04-07  9:31 ` Christian Barthel
2022-04-07 10:57   ` Emanuel Berg
2022-04-09 23:23   ` Emanuel Berg
2022-04-21  1:42   ` Emanuel Berg
2022-04-21  2:52     ` Emanuel Berg
2022-04-21  2:54     ` Emanuel Berg

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).