* Gnus exited on purpose without..
@ 2004-09-10 12:34 Harry Putnam
2004-09-10 17:52 ` colin.rafferty
0 siblings, 1 reply; 3+ messages in thread
From: Harry Putnam @ 2004-09-10 12:34 UTC (permalink / raw)
I have a batch fetch setup that runs from cron when gnus is closed.
When ever I start gnus after that batch command has been running I get:
Gnus exited on purpose without saving; read auto-save file
anyway? (y or n)
What needs to be added to my batch command code to prevent that?
emacs -batch -l ~/.emacs \
-l $HOME/.emacs-dir/batch-fetch.el \
-l ~/.gnus -f lars-fetch-news-modified
lars-fetch-news-modified looks like this:
(defun lars-fetch-news-modified ()
(interactive)
;; The let below might load ~/.gnus if "" trying nil
(let ((init-file-user "")
;; (let ((init-file-user nil)
(gnus-always-read-dribble-file t))
(gnus))
(let ((gnus-agent-confirmation-function 'gnus-agent-batch-confirmation))
(gnus-group-send-queue)
(gnus-agent-fetch-session)
(gnus-group-quit)))
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Gnus exited on purpose without..
2004-09-10 12:34 Gnus exited on purpose without Harry Putnam
@ 2004-09-10 17:52 ` colin.rafferty
2004-09-11 19:39 ` Harry Putnam
0 siblings, 1 reply; 3+ messages in thread
From: colin.rafferty @ 2004-09-10 17:52 UTC (permalink / raw)
You have to save the newsrc. See my inline change.
Speaking of saving, these are three good hooks for general gnus usage:
(add-hook 'gnus-summary-exit-hook 'gnus-dribble-save)
(add-hook 'gnus-after-getting-new-news-hook 'gnus-dribble-save)
(add-hook 'gnus-group-catchup-group-hook 'gnus-dribble-save)
Harry Putnam wrote:
> (defun lars-fetch-news-modified ()
> (interactive)
> ;; The let below might load ~/.gnus if "" trying nil
> (let ((init-file-user "")
> ;; (let ((init-file-user nil)
> (gnus-always-read-dribble-file t))
> (gnus))
> (let ((gnus-agent-confirmation-function 'gnus-agent-batch-confirmation))
> (gnus-group-send-queue)
> (gnus-agent-fetch-session)
(gnus-group-save-newsrc)
> (gnus-group-quit)))
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Gnus exited on purpose without..
2004-09-10 17:52 ` colin.rafferty
@ 2004-09-11 19:39 ` Harry Putnam
0 siblings, 0 replies; 3+ messages in thread
From: Harry Putnam @ 2004-09-11 19:39 UTC (permalink / raw)
colin.rafferty@morganstanley.com writes:
> Speaking of saving, these are three good hooks for general gnus usage:
>
> (add-hook 'gnus-summary-exit-hook 'gnus-dribble-save)
> (add-hook 'gnus-after-getting-new-news-hook 'gnus-dribble-save)
> (add-hook 'gnus-group-catchup-group-hook 'gnus-dribble-save)
I've wondered about doing something like that before... just never
hard enough to post about it... Thanks
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2004-09-11 19:39 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-09-10 12:34 Gnus exited on purpose without Harry Putnam
2004-09-10 17:52 ` colin.rafferty
2004-09-11 19:39 ` Harry Putnam
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).