Gnus development mailing list
 help / color / mirror / Atom feed
* Re: Gnus as my Fastmail main client
@ 2015-11-10 14:27 Peter Davis
  0 siblings, 0 replies; 7+ messages in thread
From: Peter Davis @ 2015-11-10 14:27 UTC (permalink / raw)
  To: lists.emacs.gnus; +Cc: ding

lists.emacs.gnus@xavier.maillard.im writes:

> I subscribed to Fastmail service and I'd like to use Gnus to access my
> messages. I do not want to start over from scratch (I lost all my .gnus
> setup years ago) so I am looking for a ready-to-use-fastmail-setup for
> Gnus. Does anybody have this ?

Below is the setup I use for Fastmail. At one point, I think I had trouble using the Fastmail smtp, so that's commented out and this
uses GMail instead. I don't remember the details, but it might be worth getting the Fastmail smtp working again. I left in some
other stuff I had commented out, in case it's useful.


(set-background-color "white")

;; @see http://www.gnu.org/software/emacs/manual/html_node/gnus/Expiring-Mail.html
;; press 'E' to expire email
(setq nnmail-expiry-target "INBOX.Trash")
(setq nnmail-expiry-wait 'immediate)
;; (setq gnus-fetch-old-headers t)
;; (setq gnus-select-method '(nnimap "mail.messagingengine.com" (nnimap-stream ssl) (nnimap-expunge-on-close ask)))
(setq user-mail-address "...")
(setq user-full-name "...")

;; (setq gnus-select-method
;;       '(nnimap "gmail"
;;                (nnimap-address "imap.gmail.com")
;;                (nnimap-server-port 993)
;;                (nnimap-stream ssl)))

(setq gnus-select-method
      '(nnimap "Fastmail" ; primary email
		(nnimap-address "mail.messagingengine.com")
		(nnimap-server-port 993)
		(nnimap-authenticator login)
		(nnimap-expunge-on-close 'never)
		(nnimap-stream ssl)
))

;; (setq gnus-select-method
;;       '(nnimap "gmail"
;; 	       (nnimap-address "imap.gmail.com")
;; 	       (nnimap-server-port 993)
;; 	       (nnimap-stream ssl)))

(setq message-send-mail-function 'smtpmail-send-it
      smtpmail-starttls-credentials '(("smtp.gmail.com" 587 nil nil))
      smtpmail-auth-credentials '(("smtp.gmail.com" 587
				   "..." nil))
      smtpmail-default-smtp-server "smtp.gmail.com"
      smtpmail-smtp-server "smtp.gmail.com"
      smtpmail-smtp-service 587
      starttls-use-gnutls t
      gnus-ignored-newsgroups "^to\\.\\|^[0-9. ]+\\( \\|$\\)\\|^[\"]\"[#'()]")

;; (setq send-mail-function 'smtpmail-send-it)
;; (setq message-send-mail-function 'smtpmail-send-it)
;; (setq smtpmail-default-smtp-server "smtps-proxy.messagingengine.com")
;; (setq smtpmail-auth-credentials '(("smtps-proxy.messagingengine.com" "80" "..." "")))
;; (setq smtpmail-starttls-credentials '(("smtps-proxy.messagingengine.com" "80" nil nil)))

(setq gnus-article-browse-delete-temp t)
(setq gnus-fetch-old-headers t)
(setq message-sendmail-envelope-from 'header)
(setq send-mail-function 'smtpmail-send-it
      message-send-mail-function 'smtpmail-send-it)
(setq smtpmail-default-smtp-server "smtps-proxy.messagingengine.com"
      smtpmail-smtp-server "smtps-proxy.messagingengine.com"
      ;; smtpmail-smtp-service 80
      ;; smtpmail-starttls-credentials '(("smtps-proxy.messagingengine.com" 80 nil nil)))
      smtpmail-starttls-credentials '(("smtps-proxy.messagingengine.com" nil nil nil)))
(setq smtpmail-stream-type 'tls)

(setq fill-flowed-display-column nil)

(add-hook 'gnus-article-mode-hook
  (lambda ()
    (setq
     truncate-lines nil
     word-wrap t)))

(setq gnus-posting-styles
      '((".*"
         (name "...")
         (address "...")
         (BCC "..."))))

(setq gnus-html-frame-width 180)
(defun my-message-mode-setup ()
  (setq fill-column 132)
  (turn-on-auto-fill))
(add-hook 'message-mode-hook 'my-message-mode-setup)

;;switch to gnus group buffer or start gnus
(defun my-switch-to-gnus-group-buffer ()
  "Switch to gnus group buffer if it exists, otherwise start gnus"
  (interactive)
  (if (or (not (fboundp 'gnus-alive-p))
          (not (gnus-alive-p)))
      (gnus)
    (switch-to-buffer "*Group*")))
(global-set-key (kbd "C-c n") 'my-switch-to-gnus-group-buffer)

;; Set up summary buffer to show tree view, dates
;; (dolist (c '((?\207 . ?q) (?\216 . ?x) (?\212 . ?t) (?\203 . ?m)))
;;       (aset standard-display-table (car c)
;;             (vector (create-glyph (concat "\e(0" "\e[35m" ; magenta
;;                                           (char-to-string (cdr c))
;;                                           "\e[0m" "\e(B")))))
;; (let ((val 129))
;;   (while (< val 160)
;;     (aset standard-display-table val (vector (create-glyph val)))
;;     (setq val (1+ val))))
;; (setq gnus-summary-line-format "%U%u&thread;%R%d %-5,5L %-20,20n %B%-80,80S\n"
;;       gnus-sum-thread-tree-vertical "\216"
;;       gnus-sum-thread-tree-root ""
;;       gnus-sum-thread-tree-false-root ""
;;       gnus-sum-thread-tree-indent " "
;;       gnus-sum-thread-tree-single-indent ""
;;       gnus-sum-thread-tree-leaf-with-other "\212\207>"
;;       gnus-sum-thread-tree-single-leaf "\203\207>")
;; (defun gnus-user-format-function-thread (dummy)
;;   (propertize gnus-tmp-thread-tree-header-string 'gnus-face t))

;; (let ((val 129))
;;       (while (< val 160)
;;         (aset standard-display-table val (vector (create-glyph val)))
;;         (setq val (1+ val))))
;; (setq gnus-summary-line-format "%U%R%d %-5,5L %-20,20n %B%-80,80S\n"
;;       gnus-sum-thread-tree-vertical "\232"
;;       gnus-sum-thread-tree-root ""
;;       gnus-sum-thread-tree-false-root ""
;;       gnus-sum-thread-tree-indent " "
;;       gnus-sum-thread-tree-single-indent ""
;;       gnus-sum-thread-tree-leaf-with-other "\226\223>"
;;       gnus-sum-thread-tree-single-leaf "\217\223>")

(setq-default
     gnus-summary-line-format "%U%R%z %(%&user-date;  %-15,15f  %B%s%)\n"
     gnus-user-date-format-alist '((t . "%Y-%m-%d %H:%M"))
     gnus-summary-thread-gathering-function 'gnus-gather-threads-by-references
     gnus-thread-sort-functions '(gnus-thread-sort-by-date)
     gnus-sum-thread-tree-false-root ""
     gnus-sum-thread-tree-indent " "
     gnus-sum-thread-tree-leaf-with-other "├► "
     gnus-sum-thread-tree-root ""
     gnus-sum-thread-tree-single-leaf "└► "
     gnus-sum-thread-tree-vertical "│")

;;;
;; Scrolling like mutt for group, summary, and article buffers.
;;
;; Being able to scroll the current buffer view by one line with a
;; single key, rather than having to guess a random number and recenter
;; with `C-u NUM C-l' is _very_ convenient.  Mutt binds scrolling by one

;; line to '<' and '>', and it's something I often miss when working
;; with Gnus buffers.  Thanks to the practically infinite customizability
;; of Gnus, this doesn't have to be an annoyance anymore.
 
;; (defun keramida-mutt-like-scrolling ()
;;   "Set up '<' and '>' keys to scroll down/up one line, like mutt."
;;   ;; mutt-like scrolling of summary buffers with '<' and '>' keys.
;;   (local-set-key (kbd ">") 'scroll-up-line)
;;   (local-set-key (kbd "<") 'scroll-down-line))
 
;; (add-hook 'gnus-group-mode-hook 'keramida-mutt-like-scrolling)
;; (add-hook 'gnus-summary-mode-hook 'keramida-mutt-like-scrolling)
;; (add-hook 'gnus-article-prepare-hook 'keramida-mutt-like-scrolling)

;; BBDB
;; (require 'bbdb)
;; (bbdb-initialize 'gnus 'message)

;; (require 'gnus-registry)
;; (gnus-registry-initialize)

(defun pd/alter-group-map ()
  (local-set-key "h" "jINBOX"))

;; From Peter Münster <pmlists@free.fr>
(defun pm/alter-summary-map ()
  (local-set-key "d" [?M ?M ?e ?e down ?g])
  (local-set-key "vj" "BmINBOX.Junk Mail"))

(defun pm/alter-article-map ()
  (local-set-key "d" "MMeen"))

(add-hook 'gnus-group-mode-hook		'pd/alter-group-map)
(add-hook 'gnus-summary-mode-hook       'pm/alter-summary-map)
(add-hook 'gnus-article-mode-hook       'pm/alter-article-map)

;;  insert x-face
(defun mail-insert-x-face ()
  (save-excursion
    (goto-char (point-min))
    (search-forward mail-header-separator)
    (beginning-of-line nil)
    (insert "X-Face: ")
    (insert-file "~/xface.dat")))
(add-hook 'message-send-hook 'mail-insert-x-face)

(setq message-required-headers ())
(setq message-required-mail-headers
      (nconc message-required-headers
             (list '(Face . (lambda ()
                              (gnus-face-from-file "~/Dropbox/pd-logo-face.png"))))))



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

* Re: Gnus as my Fastmail main client
  2015-11-11 20:02     ` Tassilo Horn
  2015-11-11 20:48       ` lists.emacs.gnus
@ 2015-11-12  4:36       ` Xavier Maillard
  1 sibling, 0 replies; 7+ messages in thread
From: Xavier Maillard @ 2015-11-12  4:36 UTC (permalink / raw)
  To: ding

Tassilo Horn <tsdh@gnu.org> writes:

> "Xavier Maillard" <lists.emacs.gnus@xavier.maillard.im> writes:
>> Ok, understand.  Where are stored settings when using G c in the Group
>> buffer?  They do not appear in the `gnus-parameters' variable.
>
> Ah, right.  I actually don't know better than somewhere in ~/News or
> ~/Mail, I just define `gnus-parameters' in my ~/.emacs.

Found it: it is in the .newrs.eld file which can be practical at the beginning
but definetely a problem when you try to debug a weird behaviour in my
opinion.

Let's put all this stuff into my .gnus file.

Thank you

-- Xavier



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

* Re: Gnus as my Fastmail main client
  2015-11-11 20:02     ` Tassilo Horn
@ 2015-11-11 20:48       ` lists.emacs.gnus
  2015-11-12  4:36       ` Xavier Maillard
  1 sibling, 0 replies; 7+ messages in thread
From: lists.emacs.gnus @ 2015-11-11 20:48 UTC (permalink / raw)
  To: ding

Tassilo Horn <tsdh@gnu.org> writes:

> "Xavier Maillard" <lists.emacs.gnus@xavier.maillard.im> writes:
>
>>> I use `gnus-parameters' with `gcc-self' for that, e.g., there's this
>>> entry
>>>
>>> 	(,(rx "nnimap+Fastmail:INBOX.mailinglists.")
>>> 	 (gcc-self "nnml+archive:sent-mails" "nnimap+Fastmail:INBOX.Sent Items")
>>> 	 (gnus-use-scoring t)
>>> 	 (subscribed . t)
>>> 	 (gnus-add-to-list t)
>>> 	 ;; Automatically expire (delete!) messages after one year.
>>> 	 (total-expire . t)
>>> 	 (expiry-wait . 365)
>>> 	 (expiry-target . delete))
>>>
>>> for my mailinglist groups.
>>
>> Is it different than:
>>
>>  (setq gnus-message-archive-group
>> 	'((if (message-news-p)
>> 	      "misc-news"
>> 	    "nnimap+Local:INBOX.Sent Items")))
>
> It's more flexible.  I have 3 email accounts and therefore have 3
> different server-side sent mail folders.  And as you can see above, I
> also use multiple sent mail folders, one local and one remote, so that I
> never ever lose a mail due to a network problem.

Sounds a pretty good idea !

Thank you

-- Xavier



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

* Re: Gnus as my Fastmail main client
  2015-11-11  7:57   ` Xavier Maillard
@ 2015-11-11 20:02     ` Tassilo Horn
  2015-11-11 20:48       ` lists.emacs.gnus
  2015-11-12  4:36       ` Xavier Maillard
  0 siblings, 2 replies; 7+ messages in thread
From: Tassilo Horn @ 2015-11-11 20:02 UTC (permalink / raw)
  To: Xavier Maillard; +Cc: ding

"Xavier Maillard" <lists.emacs.gnus@xavier.maillard.im> writes:

>> I use `gnus-parameters' with `gcc-self' for that, e.g., there's this
>> entry
>>
>> 	(,(rx "nnimap+Fastmail:INBOX.mailinglists.")
>> 	 (gcc-self "nnml+archive:sent-mails" "nnimap+Fastmail:INBOX.Sent Items")
>> 	 (gnus-use-scoring t)
>> 	 (subscribed . t)
>> 	 (gnus-add-to-list t)
>> 	 ;; Automatically expire (delete!) messages after one year.
>> 	 (total-expire . t)
>> 	 (expiry-wait . 365)
>> 	 (expiry-target . delete))
>>
>> for my mailinglist groups.
>
> Is it different than:
>
>  (setq gnus-message-archive-group
> 	'((if (message-news-p)
> 	      "misc-news"
> 	    "nnimap+Local:INBOX.Sent Items")))

It's more flexible.  I have 3 email accounts and therefore have 3
different server-side sent mail folders.  And as you can see above, I
also use multiple sent mail folders, one local and one remote, so that I
never ever lose a mail due to a network problem.

>>>  => What is the difference between gnus-parameters and
>>>  gnus-group-parameters ?
>>
>> `gnus-parameters' are frequently called group parameters, and there
>> is no variable gnus-group-parameters.
>
> Ok, understand.  Where are stored settings when using G c in the Group
> buffer?  They do not appear in the `gnus-parameters' variable.

Ah, right.  I actually don't know better than somewhere in ~/News or
~/Mail, I just define `gnus-parameters' in my ~/.emacs.

Bye,
Tassilo



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

* Re: Gnus as my Fastmail main client
  2015-11-10 20:14 ` Tassilo Horn
@ 2015-11-11  7:57   ` Xavier Maillard
  2015-11-11 20:02     ` Tassilo Horn
  0 siblings, 1 reply; 7+ messages in thread
From: Xavier Maillard @ 2015-11-11  7:57 UTC (permalink / raw)
  To: lists.emacs.gnus; +Cc: ding

Tassilo Horn <tsdh@gnu.org> writes:

> lists.emacs.gnus@xavier.maillard.im writes:
>
>>  => how can I choose my INBOX.Sent Items group as my archive group (I
>>  have tried many syntaxes but none worked)
>
> I use `gnus-parameters' with `gcc-self' for that, e.g., there's this
> entry
>
> 	(,(rx "nnimap+Fastmail:INBOX.mailinglists.")
> 	 (gcc-self "nnml+archive:sent-mails" "nnimap+Fastmail:INBOX.Sent Items")
> 	 (gnus-use-scoring t)
> 	 (subscribed . t)
> 	 (gnus-add-to-list t)
> 	 ;; Automatically expire (delete!) messages after one year.
> 	 (total-expire . t)
> 	 (expiry-wait . 365)
> 	 (expiry-target . delete))
>
> for my mailinglist groups.

Is it different than:

 (setq gnus-message-archive-group
	'((if (message-news-p)
	      "misc-news"
	    "nnimap+Local:INBOX.Sent Items")))

>>  => What is the difference between gnus-parameters and
>>  gnus-group-parameters ?
>
> `gnus-parameters' are frequently called group parameters, and there is
> no variable gnus-group-parameters.

Ok, understand. Where are stored settings when using G c in the Group buffer ?
They do not appear in the `gnus-parameters' variable.

Thank you

-- Xavier




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

* Re: Gnus as my Fastmail main client
  2015-11-10  6:03 lists.emacs.gnus
@ 2015-11-10 20:14 ` Tassilo Horn
  2015-11-11  7:57   ` Xavier Maillard
  0 siblings, 1 reply; 7+ messages in thread
From: Tassilo Horn @ 2015-11-10 20:14 UTC (permalink / raw)
  To: lists.emacs.gnus; +Cc: ding

lists.emacs.gnus@xavier.maillard.im writes:

>  => how can I choose my INBOX.Sent Items group as my archive group (I
>  have tried many syntaxes but none worked)

I use `gnus-parameters' with `gcc-self' for that, e.g., there's this
entry

	(,(rx "nnimap+Fastmail:INBOX.mailinglists.")
	 (gcc-self "nnml+archive:sent-mails" "nnimap+Fastmail:INBOX.Sent Items")
	 (gnus-use-scoring t)
	 (subscribed . t)
	 (gnus-add-to-list t)
	 ;; Automatically expire (delete!) messages after one year.
	 (total-expire . t)
	 (expiry-wait . 365)
	 (expiry-target . delete))

for my mailinglist groups.

>  => What is the difference between gnus-parameters and
>  gnus-group-parameters ?

`gnus-parameters' are frequently called group parameters, and there is
no variable gnus-group-parameters.

Bye,
Tassilo



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

* Gnus as my Fastmail main client
@ 2015-11-10  6:03 lists.emacs.gnus
  2015-11-10 20:14 ` Tassilo Horn
  0 siblings, 1 reply; 7+ messages in thread
From: lists.emacs.gnus @ 2015-11-10  6:03 UTC (permalink / raw)
  To: ding

Hello,

I subscribed to Fastmail service and I'd like to use Gnus to access my
messages. I do not want to start over from scratch (I lost all my .gnus
setup years ago) so I am looking for a ready-to-use-fastmail-setup for
Gnus. Does anybody have this ?

I know Fastmail shares many /features/ Gnus have: expiry mechanism,
spam/ham learning, group parameters, identities, etc. Do you think there
could be some sort of Gnus<->Fastmail interface to take all this power
without having to double-do the setup job ?

I have many other FR and questions on all this stuff but if you could,
at least, answer these two extras: 

 => how can I choose my INBOX.Sent Items group as my archive group (I
 have tried many syntaxes but none worked)
 => What is the difference between gnus-parameters and
 gnus-group-parameters ?

Thank you very much

I am happy to use my good ol' Gnus again ^^

Regards,

-- Xavier



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

end of thread, other threads:[~2015-11-12  4:36 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-11-10 14:27 Gnus as my Fastmail main client Peter Davis
  -- strict thread matches above, loose matches on Subject: below --
2015-11-10  6:03 lists.emacs.gnus
2015-11-10 20:14 ` Tassilo Horn
2015-11-11  7:57   ` Xavier Maillard
2015-11-11 20:02     ` Tassilo Horn
2015-11-11 20:48       ` lists.emacs.gnus
2015-11-12  4:36       ` Xavier Maillard

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