Gnus development mailing list
 help / color / mirror / Atom feed
* experience setting up gnus for the first time
@ 2013-07-05 10:18 Eric S Fraga
  2013-07-05 13:08 ` Carson Chittom
  2013-07-05 13:34 ` Vegard Vesterheim
  0 siblings, 2 replies; 9+ messages in thread
From: Eric S Fraga @ 2013-07-05 10:18 UTC (permalink / raw)
  To: ding

Hello all,

I have been using gnus for years and my configuration is quite long and
convoluted.  As it (generally) works as I want it to, I haven't bothered
cleaning it up.

However, recently I had the opportunity to pretend to start from
scratch.  I broke my Android phone (a brand new Nexus 4 <sigh>) and had
to go back to my previous phone, a Nokia N900 which runs a more easily
customisable Linux (Maemo 5) than Android, say.  I really like the N900,
even though it's relatively slow, especially because it has a real
keyboard.  However, the default MUA is not to my liking.  In any case,
having upgraded the software on the N900, I noticed that I now had Emacs
24 installed!

So I decided to install the latest version of gnus from git and try to
use it from scratch.  I thought it might help new users of gnus to see
what I had to do to get a functioning setup from scratch.

The three configuration files follow.  The first is my .gnus.el file:

#+begin_src emacs-lisp
  (setq gnus-secondary-select-methods 
        '((nnimap "MainEmail"
                  (nnimap-address "my.imap.server")
                  (nnimap-inbox "INBOX")
                  (nnimap-stream ssl))
          )
        gnus-select-method '(nnnil "")
        )
#+end_src

This is relatively straightforward and simply defines the IMAP server to
access. To specify how to access this server, I use authinfo,
specifically ~/.authinfo.gpg, with contents along these lines:

  machine my.imap.server login userid.on.imap.server password mypassword port 993

At this point, I had enough to read my emails (well, including the
loading of Ma Gnus which is in the .emacs file described below).  This was
all quite easy so I was happy: it was a good start.  However, I could
not send any emails and setting up SMTP in Emacs proved more
challenging.

After much playing around, my final .emacs configuration file contains
the following, mostly related to the SMTP configuration:

#+begin_src emacs-lisp
  (add-to-list 'load-path "~/git/gnus/lisp")
  (require 'gnus-load)
  (setq 
   mail-host-address "my.mail.domain"
   smtpmail-mail-address "me@my.mail.domain"
   )
  (custom-set-variables
   ;; custom-set-variables was added by Custom.
   ;; If you edit it by hand, you could mess it up, so be careful.
   ;; Your init file should contain only one such instance.
   ;; If there is more than one, they won't work right.
   '(gnus-posting-styles (quote ((".*" (signature-file "~/.signature-n900.txt")))))
   '(gnus-use-adaptive-scoring (quote (line)))
   '(message-send-mail-function (quote message-smtpmail-send-it))
   '(send-mail-function (quote smtpmail-send-it))
   '(smtpmail-default-smtp-server "my.imap.server")
   '(smtpmail-local-domain "my.mail.domain")
   '(smtpmail-smtp-server "my.imap.server")
   '(smtpmail-smtp-service 587)
   '(smtpmail-smtp-user "userid.on.imap.server")
   '(smtpmail-stream-type (quote starttls))
   '(user-full-name "My Full Name")
   '(user-mail-address "me@my.mail.domain"))
#+end_src

This was less obvious.  Getting SMTP to work required identifying a
whole slew of variables, with the various settings shown here.  I am not
yet sure which of these are superfluous but this full set did enable
both fetching and sending of emails.  The annoying aspect is having the
same information (e.g. mail address, server) repeated in the
configuration.

On my larger systems, I do not use Emacs SMTP to send emails, relying on
external tools.  Hence, I had no experience in configuring this aspect
of Emacs.  Maybe others can chime in...

The posting style and the adaptive scoring included above are *not*
necessary but they are quite useful.  

I now have a fully functioning gnus on my little pocket computer, aka a
phone!

I hope this proves useful to any gnus n00bs wanting to use what is, in
my opinion, the best MUA available on any system!

-- 
: Eric S Fraga, GnuPG: 0xFFFCF67D
: in Emacs 24.3.50.1 + Ma Gnus v0.8 + evil 1.0.5
: BBDB version 3.02 ($Date: 2013/05/15 13:17:58 $)




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

* Re: experience setting up gnus for the first time
  2013-07-05 10:18 experience setting up gnus for the first time Eric S Fraga
@ 2013-07-05 13:08 ` Carson Chittom
  2013-07-05 16:11   ` Eric S Fraga
  2013-07-05 13:34 ` Vegard Vesterheim
  1 sibling, 1 reply; 9+ messages in thread
From: Carson Chittom @ 2013-07-05 13:08 UTC (permalink / raw)
  To: ding

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

> This was less obvious.  Getting SMTP to work required identifying a
> whole slew of variables, with the various settings shown here.  I am not
> yet sure which of these are superfluous but this full set did enable
> both fetching and sending of emails.  The annoying aspect is having the
> same information (e.g. mail address, server) repeated in the
> configuration.

I'm using the Gnus bundled with Emacs 24, rather than from the git
repository, but the first time I tried to send a message, Emacs asked me
whether I wanted to use /usr/bin/sendmail, SMTP, or...there was one
other option, which I forget.  Having selected SMTP, it prompted me for
the correct values (server name and so on) and set them in ~/.emacs, and
I never had to manually configure anything.  Not sure why it didn't work
for you?






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

* Re: experience setting up gnus for the first time
  2013-07-05 10:18 experience setting up gnus for the first time Eric S Fraga
  2013-07-05 13:08 ` Carson Chittom
@ 2013-07-05 13:34 ` Vegard Vesterheim
  1 sibling, 0 replies; 9+ messages in thread
From: Vegard Vesterheim @ 2013-07-05 13:34 UTC (permalink / raw)
  To: ding

On Fri, 5 Jul 2013 11:18:17 +0100 Eric S Fraga <e.fraga@ucl.ac.uk> wrote:

> However, I could not send any emails and setting up SMTP in Emacs
> proved more challenging.

What if Gnus supported something like this:

https://developer.mozilla.org/en-US/docs/Thunderbird/Autoconfiguration

 - Vegard V -



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

* Re: experience setting up gnus for the first time
  2013-07-05 13:08 ` Carson Chittom
@ 2013-07-05 16:11   ` Eric S Fraga
  2013-07-05 18:46     ` Carson Chittom
  2013-07-06  3:28     ` Eric Abrahamsen
  0 siblings, 2 replies; 9+ messages in thread
From: Eric S Fraga @ 2013-07-05 16:11 UTC (permalink / raw)
  To: ding

Carson Chittom <carson@wistly.net> writes:

> Eric S Fraga <e.fraga@ucl.ac.uk> writes:
>
>> This was less obvious.  Getting SMTP to work required identifying a
>> whole slew of variables, with the various settings shown here.  I am not
>> yet sure which of these are superfluous but this full set did enable
>> both fetching and sending of emails.  The annoying aspect is having the
>> same information (e.g. mail address, server) repeated in the
>> configuration.
>
> I'm using the Gnus bundled with Emacs 24, rather than from the git
> repository, but the first time I tried to send a message, Emacs asked me
> whether I wanted to use /usr/bin/sendmail, SMTP, or...there was one
> other option, which I forget.  Having selected SMTP, it prompted me for
> the correct values (server name and so on) and set them in ~/.emacs, and
> I never had to manually configure anything.  Not sure why it didn't work
> for you?

To be fair, the difficulties could be due to my using the Live@ system
from Microsoft where the server name and the domain name are completely
different, as are the userid and the actual email address.  In any case,
I don't know.  The system did prompt for some fields but these were not
enough.  I wish I had taken notes but I didn't.

It would be useful to know what variables Emacs set for your
configuration.  Maybe post them?  

I posted the above in the hope that, if anybody else that has any
problems, they will see what variables may need setting.

And I should make it clear that I wasn't complaining.  It was simply
that fetching email was very straightforward whereas sending was
somewhat less so which surprised me.

thanks,
eric

-- 
: Eric S Fraga, GnuPG: 0xFFFCF67D
: in Emacs 24.3.50.1 + Ma Gnus v0.8 + evil 1.0.5
: BBDB version 3.02 ($Date: 2013/05/15 13:17:58 $)




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

* Re: experience setting up gnus for the first time
  2013-07-05 16:11   ` Eric S Fraga
@ 2013-07-05 18:46     ` Carson Chittom
  2013-07-08 10:55       ` Eric S Fraga
  2013-07-08 12:21       ` Ted Zlatanov
  2013-07-06  3:28     ` Eric Abrahamsen
  1 sibling, 2 replies; 9+ messages in thread
From: Carson Chittom @ 2013-07-05 18:46 UTC (permalink / raw)
  To: ding

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

> Carson Chittom <carson@wistly.net> writes:
>> I'm using the Gnus bundled with Emacs 24, rather than from the git
>> repository, but the first time I tried to send a message, Emacs asked me
>> whether I wanted to use /usr/bin/sendmail, SMTP, or...there was one
>> other option, which I forget.  Having selected SMTP, it prompted me for
>> the correct values (server name and so on) and set them in ~/.emacs, and
>> I never had to manually configure anything.  Not sure why it didn't work
>> for you?
>
> To be fair, the difficulties could be due to my using the Live@ system
> from Microsoft where the server name and the domain name are completely
> different, as are the userid and the actual email address.  In any case,
> I don't know.  The system did prompt for some fields but these were not
> enough.  I wish I had taken notes but I didn't.
>
> It would be useful to know what variables Emacs set for your
> configuration.  Maybe post them?  

Hmm...looks like it did the following to ~/.emacs

(custom-set-variables
 '(send-mail-function (quote smtpmail-send-it))
 '(smtpmail-smtp-server "smtp.example.com")
 '(smtpmail-smtp-service 587))

And set up the line in ~/.authinfo, and that was it.






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

* Re: experience setting up gnus for the first time
  2013-07-05 16:11   ` Eric S Fraga
  2013-07-05 18:46     ` Carson Chittom
@ 2013-07-06  3:28     ` Eric Abrahamsen
  2013-07-08 10:57       ` Eric S Fraga
  1 sibling, 1 reply; 9+ messages in thread
From: Eric Abrahamsen @ 2013-07-06  3:28 UTC (permalink / raw)
  To: ding

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

> Carson Chittom <carson@wistly.net> writes:
>
>> Eric S Fraga <e.fraga@ucl.ac.uk> writes:
>>
>>> This was less obvious.  Getting SMTP to work required identifying a
>>> whole slew of variables, with the various settings shown here.  I am not
>>> yet sure which of these are superfluous but this full set did enable
>>> both fetching and sending of emails.  The annoying aspect is having the
>>> same information (e.g. mail address, server) repeated in the
>>> configuration.
>>
>> I'm using the Gnus bundled with Emacs 24, rather than from the git
>> repository, but the first time I tried to send a message, Emacs asked me
>> whether I wanted to use /usr/bin/sendmail, SMTP, or...there was one
>> other option, which I forget.  Having selected SMTP, it prompted me for
>> the correct values (server name and so on) and set them in ~/.emacs, and
>> I never had to manually configure anything.  Not sure why it didn't work
>> for you?
>
> To be fair, the difficulties could be due to my using the Live@ system
> from Microsoft where the server name and the domain name are completely
> different, as are the userid and the actual email address.  In any case,
> I don't know.  The system did prompt for some fields but these were not
> enough.  I wish I had taken notes but I didn't.
>
> It would be useful to know what variables Emacs set for your
> configuration.  Maybe post them?  
>
> I posted the above in the hope that, if anybody else that has any
> problems, they will see what variables may need setting.
>
> And I should make it clear that I wasn't complaining.  It was simply
> that fetching email was very straightforward whereas sending was
> somewhat less so which surprised me.

It was only after using gnus that I first realized that the processes of
sending and receiving mail were completely separate, that was definitely
a surprise. Right now I use msmtp in linux to handle mail sending, which
means far less configuration in gnus, but the exact same variables still
have to be set in .msmtprc. I don't think there's any way around that!
Automation is the most you can hope for.

Eric




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

* Re: experience setting up gnus for the first time
  2013-07-05 18:46     ` Carson Chittom
@ 2013-07-08 10:55       ` Eric S Fraga
  2013-07-08 12:21       ` Ted Zlatanov
  1 sibling, 0 replies; 9+ messages in thread
From: Eric S Fraga @ 2013-07-08 10:55 UTC (permalink / raw)
  To: ding

Carson Chittom <carson@wistly.net> writes:

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

[...]

>> It would be useful to know what variables Emacs set for your
>> configuration.  Maybe post them?  
>
> Hmm...looks like it did the following to ~/.emacs
>
> (custom-set-variables
>  '(send-mail-function (quote smtpmail-send-it))
>  '(smtpmail-smtp-server "smtp.example.com")
>  '(smtpmail-smtp-service 587))

yes, I think Emacs set the same variables for me.  The problem, in my
case, is that the server is based at outlook.com and sending emails
requires the From field to be a valid address that jives with my login
but is not the actual login.  Obviously, the automation from Emacs does
not cater for this case!

Anyway, as I said earlier, I hope my contribution to the list will help
some future user new to gnus/emacs!

thanks,
eric

-- 
: Eric S Fraga, GnuPG: 0xFFFCF67D
: in Emacs 24.3.50.1 + Ma Gnus v0.8 + evil 1.0.5
: BBDB version 3.02 ($Date: 2013/05/15 13:17:58 $)




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

* Re: experience setting up gnus for the first time
  2013-07-06  3:28     ` Eric Abrahamsen
@ 2013-07-08 10:57       ` Eric S Fraga
  0 siblings, 0 replies; 9+ messages in thread
From: Eric S Fraga @ 2013-07-08 10:57 UTC (permalink / raw)
  To: ding

Eric Abrahamsen <eric@ericabrahamsen.net> writes:

[...]

> It was only after using gnus that I first realized that the processes of
> sending and receiving mail were completely separate, that was definitely
> a surprise. 

Yes, they are completely separate.  Some MUAs make this quite clear
(Thunderbird comes to mind) whereas many others do not.

> Right now I use msmtp in linux to handle mail sending, which

As do I generally.

> I don't think there's any way around that!
> Automation is the most you can hope for.

Yes, Emacs tries hard but cannot guess all edge cases.

-- 
: Eric S Fraga, GnuPG: 0xFFFCF67D
: in Emacs 24.3.50.1 + Ma Gnus v0.8 + evil 1.0.5
: BBDB version 3.02 ($Date: 2013/05/15 13:17:58 $)




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

* Re: experience setting up gnus for the first time
  2013-07-05 18:46     ` Carson Chittom
  2013-07-08 10:55       ` Eric S Fraga
@ 2013-07-08 12:21       ` Ted Zlatanov
  1 sibling, 0 replies; 9+ messages in thread
From: Ted Zlatanov @ 2013-07-08 12:21 UTC (permalink / raw)
  To: ding

On Fri, 05 Jul 2013 13:46:50 -0500 Carson Chittom <carson@wistly.net> wrote: 

CC> Eric S Fraga <e.fraga@ucl.ac.uk> writes:
>> Carson Chittom <carson@wistly.net> writes:
>>> I'm using the Gnus bundled with Emacs 24, rather than from the git
>>> repository, but the first time I tried to send a message, Emacs asked me
>>> whether I wanted to use /usr/bin/sendmail, SMTP, or...there was one
>>> other option, which I forget.  Having selected SMTP, it prompted me for
>>> the correct values (server name and so on) and set them in ~/.emacs, and
>>> I never had to manually configure anything.  Not sure why it didn't work
>>> for you?
>> 
>> To be fair, the difficulties could be due to my using the Live@ system
>> from Microsoft where the server name and the domain name are completely
>> different, as are the userid and the actual email address.  In any case,
>> I don't know.  The system did prompt for some fields but these were not
>> enough.  I wish I had taken notes but I didn't.
>> 
>> It would be useful to know what variables Emacs set for your
>> configuration.  Maybe post them?  

CC> Hmm...looks like it did the following to ~/.emacs

CC> (custom-set-variables
CC>  '(send-mail-function (quote smtpmail-send-it))
CC>  '(smtpmail-smtp-server "smtp.example.com")
CC>  '(smtpmail-smtp-service 587))

CC> And set up the line in ~/.authinfo, and that was it.

Hi Carson and Eric,

maybe the two of you could write a walkthrough of Eric's first-time
setup that covers the "recommended" way to do things and then points to
the reference manual for details?  Eric did most of this already but it
would be nice to have it in a format we can show new users.

Eric's story was a very nice view into how simple Gnus is to set up. I
often forget that, having used it for so many years.  My personal
configuration is probably too complicated!

Thanks!
Ted




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

end of thread, other threads:[~2013-07-08 12:21 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-05 10:18 experience setting up gnus for the first time Eric S Fraga
2013-07-05 13:08 ` Carson Chittom
2013-07-05 16:11   ` Eric S Fraga
2013-07-05 18:46     ` Carson Chittom
2013-07-08 10:55       ` Eric S Fraga
2013-07-08 12:21       ` Ted Zlatanov
2013-07-06  3:28     ` Eric Abrahamsen
2013-07-08 10:57       ` Eric S Fraga
2013-07-05 13:34 ` Vegard Vesterheim

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