Gnus development mailing list
 help / color / mirror / Atom feed
* How to change the default gnus-message-archive-method?
@ 2005-08-31 18:39 Rodolfo Medina
  2005-09-01  0:56 ` Katsumi Yamaoka
  0 siblings, 1 reply; 4+ messages in thread
From: Rodolfo Medina @ 2005-08-31 18:39 UTC (permalink / raw)


It seems that I don't manage to change at my pleasure
the gnus-message-archive-method variable.
On page 119 of Gnus Manual it is said that I can change the default, which is:

(nnfolder "archive"
		 (nnfolder-directory "~/Mail/archive")
		 (nnfolder-active-file "~/Mail/archive/active")
		 (nnfolder-get-new-mail nil)
		 (nnfolder-inhibit-expiry t))
		 
, with something like:

(setq gnus-message-archive-method
	'(nnfolder "archive"
		 (nnfolder-inhibit-expiry t)
		 (nnfolder-active-file "~/News/sent-mail/active")
		 (nnfolder-directory "~/News/sent-mail/")))
		 
, but it doesn't work: 
I put in my .gnus.el that stuff but the default values did not change.
Please, any thought?

Thanks,
Rodolfo





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

* Re: How to change the default gnus-message-archive-method?
  2005-08-31 18:39 How to change the default gnus-message-archive-method? Rodolfo Medina
@ 2005-09-01  0:56 ` Katsumi Yamaoka
  0 siblings, 0 replies; 4+ messages in thread
From: Katsumi Yamaoka @ 2005-09-01  0:56 UTC (permalink / raw)
  Cc: ding

>>>>> In <loom.20050831T203912-991@post.gmane.org> Rodolfo Medina wrote:

> It seems that I don't manage to change at my pleasure
> the gnus-message-archive-method variable.
> On page 119 of Gnus Manual it is said that I can change the default, which is:

[...]

> , with something like:

> (setq gnus-message-archive-method
> 	'(nnfolder "archive"
> 		 (nnfolder-inhibit-expiry t)
> 		 (nnfolder-active-file "~/News/sent-mail/active")
> 		 (nnfolder-directory "~/News/sent-mail/")))

> , but it doesn't work: 

How doesn't it work?  What is the value you've set to the
`gnus-message-archive-group' variable?  What is the Gnus version
you are using?

> I put in my .gnus.el that stuff but the default values did not change.

If you mean the values of `nnfolder-directory', etc., their
values which can be observed by using `C-h v' won't change.
They will be bound to the values specified by
`gnus-message-archive-method' only when archiving articles.

While I normally use

(setq gnus-message-archive-method '(nnml ""))

, I tried the following configuration:

(setq gnus-message-archive-method
      '(nnfolder "archive"
		 (nnfolder-inhibit-expiry t)
		 (nnfolder-active-file "~/News/sent-mail/active")
		 (nnfolder-directory "~/News/sent-mail/")))

(setq gnus-message-archive-group "all")

There's no problem.  All the sent message were saved in:

~/News/sent-mail/all



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

* Re: How to change the default gnus-message-archive-method?
  2005-09-01 11:01 romeomedina
@ 2005-09-02  6:23 ` Katsumi Yamaoka
  0 siblings, 0 replies; 4+ messages in thread
From: Katsumi Yamaoka @ 2005-09-02  6:23 UTC (permalink / raw)
  Cc: ding

>>>>> In <IM4X9O$82198AFDD420649AC1B63D82C0B2AE92@libero.it>
>>>>>	"romeomedina\@libero\.it" <romeomedina@libero.it> wrote:

> Katsumi Yamaoka wrote:

>> How doesn't it work?  What is the value you've set to the
>> `gnus-message-archive-group' variable?  What is the Gnus version
>> you are using?

> It doesn't work in the sense that gnus is going on storing the mail
> I send in its default `~/Mail/archive' directory.
> I've set the `gnus-message-archive-group' variable to the value 'all'.
> I'm using the Gnus version 5.11, included in Emacs CVS 21.3.50.1 of 2005-03-13.

I guess you have the default archive method in your ~/.newsrc.eld
file.  To examine it, type

C-h v gnus-server-alist RET

after starting up Gnus.  Isn't there an item like the following?

 ("archive" nnfolder "archive"
  (nnfolder-directory "~/Mail/archive")
  (nnfolder-active-file "~/Mail/archive/active")
  (nnfolder-get-new-mail nil)
  (nnfolder-inhibit-expiry t))

If it exists, it may have been made when the value of the
`gnus-message-archive-method' variable was "archive" (which is
the default).

Probably, the following header will appear in your message buffers.

Gcc: nnfolder+archive:all

When sending a message, Gnus parses the value of that header and
determine the method to archive the sent message.  At that time,
if the `gnus-server-alist' variable holds the "archive" method, Gnus
uses it rather than the one defined in `gnus-message-archive-method'.
Furthermore, there's no opportunity to update the "archive" method
held in `gnus-server-alist'.  We may say it is a bug.  I don't have
an idea to fix it, though.

If your case comes under this, it will be solvable by the following
ways.

1. Start Emacs; start Gnus; quit Gnus, but don't quit Emacs.

2. Make a backup of the ~/.newsrc.eld file.

3. Copy the following Lisp form into the *scratch* buffer, and
   evaluate it (type `C-j' at the end of the last line).

(let ((file "~/.newsrc.eld")
      (coding-system-for-read gnus-ding-file-coding-system)
      (coding-system-for-write gnus-ding-file-coding-system)
      (default-enable-multibyte-characters t)
      (print-quoted t) (print-readably t) (print-escape-multibyte nil)
      (print-escape-nonascii t) (print-length nil) (print-level nil)
      (print-escape-newlines t)
      start alist arc)
  (with-temp-buffer
    (insert-file-contents file)
    (goto-char (point-min))
    (when (re-search-forward "([\t\n ]*setq[\t\n ]+gnus-server-alist[\t\n ]"
			     nil t)
      (goto-char (setq start (match-beginning 0)))
      (setq alist (car (cdr (car (cdr (cdr (read (current-buffer))))))))
      (skip-chars-forward "\t\n ")
      (delete-region start (point))
      (while (setq arc (assoc "archive" alist))
	(setq alist (delq arc alist)))
      (insert "(setq gnus-server-alist '" (prin1-to-string alist) ")\n")
      (write-region (point-min) (point-max) file))))

4. Start Gnus.



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

* Re: How to change the default gnus-message-archive-method?
@ 2005-09-01 11:01 romeomedina
  2005-09-02  6:23 ` Katsumi Yamaoka
  0 siblings, 1 reply; 4+ messages in thread
From: romeomedina @ 2005-09-01 11:01 UTC (permalink / raw)
  Cc: ding

Rodolfo Medina wrote:

> It seems that I don't manage to customize
> the gnus-message-archive-method variable.
> On page 119 of Gnus Manual it is said that I can change the default, which is:
>
> (nnfolder "archive"
>		 (nnfolder-directory "~/Mail/archive")
>		 (nnfolder-active-file "~/Mail/archive/active")
>		 (nnfolder-get-new-mail nil)
>		 (nnfolder-inhibit-expiry t))
>
> , with something like:
>
> (setq gnus-message-archive-method
>	'(nnfolder "archive"
>		 (nnfolder-inhibit-expiry t)
>		 (nnfolder-active-file "~/News/sent-mail/active")
>		 (nnfolder-directory "~/News/sent-mail/")))
>
> , but it doesn't work:
> I put in my .gnus.el that stuff but the default values did not change.



Katsumi Yamaoka wrote:

> How doesn't it work?  What is the value you've set to the
> `gnus-message-archive-group' variable?  What is the Gnus version
> you are using?


It doesn't work in the sense that gnus is going on storing the mail
I send in its default `~/Mail/archive' directory.
I've set the `gnus-message-archive-group' variable to the value 'all'.
I'm using the Gnus version 5.11, included in Emacs CVS 21.3.50.1 of 2005-03-13.


Katsumi:

> If you mean the values of `nnfolder-directory', etc., their
> values which can be observed by using `C-h v' won't change.
> They will be bound to the values specified by
> `gnus-message-archive-method' only when archiving articles.


I did: `C-h v gnus-message-archive-method', and the following appeared:

-----------------------------------------------------------------------
	gnus-message-archive-method's value is
	(nnfolder "archive"
		  (nnfolder-inhibit-expiry t)
		  (nnfolder-active-file "~/News/sent-mail/active")
		  (nnfolder-directory "~/News/sent-mail/"))


	*Method used for archiving messages you've sent.
	This should be a mail method.

	You can customize this variable.

	Defined in `gnus'.
-----------------------------------------------------------------------

, but, as I said before, sent mail is going on being stored
in the default directory `~/Mail/archive'.


Katsumi:

> While I normally use
>
> (setq gnus-message-archive-method '(nnml ""))
>
> , I tried the following configuration:
>
> (setq gnus-message-archive-method
>      '(nnfolder "archive"
>		 (nnfolder-inhibit-expiry t)
>		 (nnfolder-active-file "~/News/sent-mail/active")
>		 (nnfolder-directory "~/News/sent-mail/")))
>
> (setq gnus-message-archive-group "all")
>
> There's no problem.  All the sent message were saved in:
>
> ~/News/sent-mail/all


. Instead, I have problem: gnus is going on storing the mail
I send in `~/Mail/archive'.

I'm really stuck! Any idea?
I'm showing my whole .gnus.el.

Thanks indeed,
Rodolfo


-----------------------------------------------------------------
(setq user-mail-address "rodolfo.medina@libero.it")
(setq user-full-name "Rodolfo Medina")


(setq gnus-select-method '(nnml "received-mail"
				(nnml-directory "~/mail-prova")
))



(setq mail-sources '((pop :server "popmail.libero.it"
                          :user "rodolfo.medina"
)))

(setq send-mail-function 'smtpmail-send-it)
(setq message-send-mail-function 'smtpmail-send-it)
(setq smtpmail-default-smtp-server "mail.libero.it")
(setq gnus-agent t)

(setq gnus-message-archive-method
      '(nnfolder "archive"
		 (nnfolder-inhibit-expiry t)
		 (nnfolder-active-file "~/News/sent-mail/active")
		 (nnfolder-directory "~/News/sent-mail/")))

(setq gnus-message-archive-group "all")

(setq nndraft-directory "~/mail-prova2")

(setq mm-text-html-renderer 'w3m)
(setq mm-inline-text-html-with-images t)
(setq mm-w3m-safe-url-regexp nil)
(setq message-send-mail-partially-limit nil)

(setq gnus-show-all-headers t)
------------------------------------------------------------------------




____________________________________________________________
6X velocizzare la tua navigazione a 56k? 6X Web Accelerator di Libero!
Scaricalo su INTERNET GRATIS 6X http://www.libero.it





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

end of thread, other threads:[~2005-09-02  6:23 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-08-31 18:39 How to change the default gnus-message-archive-method? Rodolfo Medina
2005-09-01  0:56 ` Katsumi Yamaoka
2005-09-01 11:01 romeomedina
2005-09-02  6:23 ` Katsumi Yamaoka

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