From f094c0ce074662ef167bc48155c8e668c69415e3 Mon Sep 17 00:00:00 2001 From: tfheen Date: Wed, 10 Jan 2007 09:57:20 +0000 Subject: [PATCH] Add CRM headers, fix summary to display CRM score git-svn-id: file:///svn/tfheen/trunk/dotfiles@987 8da78d58-1cd3-0310-bee5-d77bd1b3e8bf --- gnus | 38 +++++++++++++++++++++++++++++++------- 1 file changed, 31 insertions(+), 7 deletions(-) diff --git a/gnus b/gnus index b0388ea..d18da13 100644 --- a/gnus +++ b/gnus @@ -107,12 +107,12 @@ inserts \" characters." (message-fetch-field "newsgroups"))))))) (if (string-match "^opera" newsgroups) (mc-sign-message "tfheen@opera.no"))))) -(cw/for-host "thosu" - (setq gnus-message-archive-group - '((if (message-news-p) - "misc-news" - (format-time-string "out.%Y.out-%Y-%m"))) - gnus-message-archive-method "nnimap+err")) +;(cw/for-host "thosu" +; (setq gnus-message-archive-group +; '((if (message-news-p) +; "misc-news" +; (format-time-string "out.%Y.out-%Y-%m"))) +; gnus-message-archive-method "nnimap+err")) (cw/for-host "vawad" (setq gnus-message-archive-group @@ -273,7 +273,7 @@ inserts \" characters." (cw/for-host "thosu" (require 'gnus-demon) - (gnus-demon-add-handler 'gnus-group-get-new-news 10 2) +; (gnus-demon-add-handler 'gnus-group-get-new-news 10 2) (gnus-demon-add-handler 'gnus-demon-close-connections 5 t) (gnus-demon-init) ) @@ -623,9 +623,18 @@ on multiple mail-followup-to headers" (gnus-summary-move-article nil (format-time-string "spam.%Y-%m") nil 'move) (gnus-summary-next-subject 1)) +(defun tfheen-kill-ring-cacheid () + (interactive) + (save-excursion + (set-buffer gnus-article-buffer) + (message-narrow-to-headers-or-head) + (kill-new (message-fetch-field "x-crm114-cacheid")) + (widen))) + (cw/for-host "yiwaz\\|thosu\\|golem\\|xoog" (define-key gnus-summary-backend-map "s" 'tfheen-mark-as-spam) (define-key gnus-summary-mode-map "z" 'tfheen-mark-as-spam) + (define-key gnus-summary-mode-map "v" 'tfheen-kill-ring-cacheid) (setq pgg-default-user-id "tfheen@raw.no") (setq gnus-subscribe-newsgroup-method 'gnus-subscribe-topics gnus-agent-synchronize-flags t)) @@ -723,3 +732,18 @@ Argument REVERSE means reverse order." (gnus-summary-sort 'message-id reverse)) (add-hook 'gnus-group-mode-hook 'gnus-topic-mode) + +(setq gnus-group-line-format "%M%S%p %5,5y/%5,5t [%2T]: %-30G %z %10D\n" + gnus-visible-headers "^From:\\|^Newsgroups:\\|^Subject:\\|^Date:\\|^Followup-To:\\|^Reply-To:\\|^Organization:\\|^Summary:\\|^Keywords:\\|^To:\\|^[BGF]?Cc:\\|^Posted-To:\\|^Mail-Copies-To:\\|^Mail-Followup-To:\\|^Apparently-To:\\|^Gnus-Warning:\\|^Resent-From:\\|^X-Sent:\\|^X-CRM114-") + +(defun gnus-user-format-function-C (header) + "Return the X-CRM114-Score value." + (let ((env (cdr (assoc 'X-CRM114-Score (mail-header-extra header))))) + (if env + env + ""))) + +(setq gnus-summary-line-format "%U%R%z%-6,6uC %I%(%[%4L: %-23,23f%]%) %s\n") + +(add-to-list 'gnus-extra-headers 'X-CRM114-Score) +(add-to-list 'nnmail-extra-headers 'X-CRM114-Score) -- 2.39.5