Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Getting Gnus to read /var/spool/mail/<name>
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
wynnmc
n00b
n00b


Joined: 01 Dec 2019
Posts: 2

PostPosted: Thu Jan 16, 2020 4:19 pm    Post subject: Getting Gnus to read /var/spool/mail/<name> Reply with quote

I've been running Gnus for a long time but it has failed on my desktop.

To get around this (the desktop is old and may be failing) I am trying to install it on my laptop.

I use fetchmail to download the emails from the (remote) mail server and they go into /var/spool/mail/<name>

I have the following ~/.gnus.el -- mainly copied from the one I've been using on the desktop but with a different gnus-secondary-select-methods to suit the new environment.

Code:
setq gnus-select-method '(nntp "usenet.plus.net"))
(setq gnus-nntp-server nil)
(setq gnus-default-article-saver 'gnus-summary-save-in-file)
(setq gnus-subscribe-newsgroup-method
      '(lambda (newsgroup)
    (gnus-subscribe-newsgroup newsgroup)
    (gnus-kill-newsgroup newsgroup)))
(setq gnus-secondary-select-methods '((nnfolder "")))
(setq nnfolder-directory "~/GNUS")

(setq mail-source
      '((file :path "/var/spool/mail/<name>")))

Obviously <name> obscures the real value...

I get this in Messages:

Code:
Reading /home/<name>/.newsrc.eld...
Opening nnfolder server on archive...done
Opening nnfolder server...done
No new newsgroups
Checking new news...
Reading active file via nnfolder...
Reading incoming mail from file...
Processing mail from ~/.emacs-mail-crash-box...
Mail source (file) failed: (file-error Read error Is a directory /home/<name>/.emacs-mail-crash-box)
nnfolder: Reading incoming mail (no new mail)...done
Reading active file via nnfolder...done
Reading active file from archive via nnfolder...done
Reading active file via nndraft...done
Checking new news...done


I've told it to read from
Code:
/var/spool/mail/<name>

-- why is it trying to read from
Code:
.emacs-mail-crash-box
?

Code:
/var/spool/mail/<name>
is there and has something in it.
Back to top
View user's profile Send private message
wynnmc
n00b
n00b


Joined: 01 Dec 2019
Posts: 2

PostPosted: Fri Jan 17, 2020 1:22 pm    Post subject: Reply with quote

It looks as though this problem doesn't concern many people.

So, for what it's worth, here is a solution:

in gnus.el replace
Code:
(setq mail-sources
      '((file :path "/var/spool/mail/<name>")))

by
Code:
(setq mail-sources
      '((maildir :path "/home/<name>/.maildir/"
             :subdirs ("cur" "new"))))

create the directory .maildir together with the two subdirectories cur and new, delete the directory .emacs-mail-crash-box and replace it with a file and copy /var/spool/mail/<name> to this file.

It now works --- but it's too much trouble!!

I will change it to
Code:
(pop :server "my.pop.server"
               :user "user-name" :password "secret")


:cry:
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum