comparison gnus-init.el @ 6:dccf9e53f179

*** empty log message ***
author ht
date Mon, 29 Aug 2005 08:51:09 +0100
parents
children 6d36ba671237
comparison
equal deleted inserted replaced
-1:000000000000 6:dccf9e53f179
1 ;; Last edited: Fri Aug 20 14:49:23 1999
2 ;; gnus customisation
3
4 (setq gnus-novice-user nil)
5
6 (setq gnus-message-archive-group
7 '((concat "general." (format-time-string
8 "%Y-%m" (current-time)))))
9
10 (setq gnus-summary-ignore-duplicates t
11 gnus-auto-select-next 'quietly
12 gnus-your-organization "HCRC, University of Edinburgh"
13 gnus-summary-line-format "%U%R%z%I%4N%(%[%4L: %-20,20n%]%) %s\n"
14 mm-discouraged-alternatives '("text/html")
15 gnus-ignored-headers
16 "^Errors-To:\\|^Precedence:\\|^UNIX-From:")
17
18 (setq bbdb/news-auto-create-p t)
19
20 (setq nnmail-crosspost nil)
21 (setq nnmail-split-methods 'nnmail-split-fancy)
22 (setq nnmail-split-fancy
23 (let ((month (format-time-string "%Y-%m" (current-time))))
24 (cons '|
25 (append '(("Subject" "testing" junk)
26 (to "quaker-\\(l\\|spectrum\\)" "quaker")
27 (to "quaker-b" "quaker-b")
28 (to "w3c-xml-schema-\\([a-z]+\\)" "xml-schema-\\1")
29 (to "w3c-xml-\\([a-z]+\\)" "xml-\\1" )
30 (to "w3c-archive" "refinement")
31 (to "w3c-\\(xsl-wg\\|format\\|i18n-ig\\)" "xsl")
32 (to "[cC]ygwin" "cygwin")
33 (to "ding" "gnus")
34 (to "zphdaily" (concat "pers-" month))
35 (to "inf\\(pg\\|msc\\|teach\\|res\\|staff\\)" "inf-\\1" )
36 )
37 (list (list 'to
38 "ht\\|h\\.?thompson?"
39 (concat "pers-" month))
40 (concat "group-"
41 (format-time-string
42 "%Y-%m" (current-time))
43 ""))))))
44 (setq gnus-show-mime t)
45
46 (defun ht-gnus-summary-delete-forward ()
47 "REAL delete for nnmail gnus"
48 (interactive)
49 (gnus-summary-delete-article)
50 (gnus-summary-next-unread-article))
51
52 (require 'my-news)
53 (custom-set-variables
54 '(gnus-treat-display-picons nil))
55 (custom-set-faces)
56
57 (add-hook 'gnus-group-mode-hook 'gnus-topic-mode)
58
59 (add-hook 'gnus-summary-mode-hook 'gnus-summary-mode-fun1)
60
61 ;; run the first time we make a summary window
62 (defun gnus-summary-mode-fun1 ()
63 "install ht's mods"
64 (define-key gnus-summary-mode-map "D" 'ht-gnus-summary-delete-forward)
65 (remove-hook 'gnus-summary-mode-hook 'gnus-summary-mode-fun1))
66
67 (defun ht-gnus-pers-refresh (n)
68 (interactive "p")
69 (let ((gn (concat "nnml+ht:pers-"
70 (format-time-string "%Y-%m" (current-time)))))
71 (gnus-group-goto-group gn)
72 (gnus-group-get-new-news-this-group n)
73 (gnus-group-goto-group gn)
74 (gnus-group-read-group))
75 )
76
77 (add-hook 'gnus-group-mode-hook 'gnus-group-mode-fun1)
78
79 ;; run the first time we make a group window
80 (defun gnus-group-mode-fun1 ()
81 "install ht's mods"
82 (define-key gnus-group-mode-map "\M-\C-g" 'ht-gnus-pers-refresh)
83 (remove-hook 'gnus-group-mode-hook 'gnus-group-mode-fun1))
84
85 (defun gnus-regen-group ()
86 (nnml-generate-nov-databases-1 (concat
87 (expand-file-name nnml-directory)
88 "/"
89 (substring (gnus-group-group-name) 8))
90 nil t)
91 )
92
93
94 (defun gnus-user-format-function-t (header)
95 "display the to field (for archive messages)"
96 (let ((n (mail-header-number header)))
97 (with-current-buffer nntp-server-buffer
98 (save-excursion
99 (save-restriction
100 (let ((inhibit-point-motion-hooks t))
101 (goto-char (point-min))
102 (let ((beg (search-forward (format " %d Article retrieved." n)))
103 (end (search-forward "\n.\n")))
104 (narrow-to-region beg end)
105 (goto-char beg)
106 (message-fetch-field "To"))))))))
107
108 (make-variable-buffer-local 'gnus-extra-headers)
109 (make-variable-buffer-local 'nnmail-extra-headers)
110 (add-hook 'gnus-parse-headers-hook
111 '(lambda ()
112 (gnus-summary-set-local-parameters gnus-newsgroup-name)))