• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.10/emacs-93/emacs/lisp/gnus/

Lines Matching +refs:news +refs:next +refs:group

7 ;; Keywords: news
51 :group 'gnus-start
59 :group 'gnus-start
70 :group 'gnus-start
77 :group 'gnus-start
88 :group 'gnus-start
96 :group 'gnus-start
103 :group 'gnus-dribble-file
110 :group 'gnus-dribble-file
140 check for new newsgroups with \\<gnus-group-mode-map>\\[gnus-find-new-newsgroups]."
141 :group 'gnus-start
153 check for bogus newsgroups with \\<gnus-group-mode-map>\\[gnus-group-check-bogus-groups]."
154 :group 'gnus-start-server
171 :group 'gnus-start-server
192 :group 'gnus-group-levels
197 :group 'gnus-group-levels
204 :group 'gnus-group-levels
219 :group 'gnus-group-levels
231 :group 'gnus-newsrc
241 :group 'gnus-newsrc
256 :group 'gnus-newsrc
275 :group 'gnus-group-new
279 "*Function(s) called with a group name when new group is detected.
289 :group 'gnus-group-new
301 "*Hooks run after you subscribe to a new group.
302 The hooks will be called with new group's name as argument."
304 :group 'gnus-group-new
318 :group 'gnus-group-new
338 :group 'gnus-group-new
350 :group 'gnus-group-new
361 :group 'gnus-group-new
369 :group 'gnus-group-new
377 :group 'gnus-newsrc
382 :group 'gnus-start-server
388 :group 'gnus-start
394 :group 'gnus-start
399 :group 'gnus-start
402 (defcustom gnus-setup-news-hook
403 '(gnus-fixup-nnimap-unread-after-getting-new-news)
405 :group 'gnus-start
408 (defcustom gnus-get-top-new-news-hook nil
409 "A hook run just before Gnus checks for new news globally."
411 :group 'gnus-group-new
414 (defcustom gnus-get-new-news-hook nil
415 "A hook run just before Gnus checks for new news."
416 :group 'gnus-group-new
419 (defcustom gnus-after-getting-new-news-hook
421 gnus-fixup-nnimap-unread-after-getting-new-news)
422 "*A hook run after Gnus checks for new news when Gnus is already running."
423 :group 'gnus-group-new
428 :group 'gnus-newsrc
433 :group 'gnus-newsrc
439 :group 'gnus-newsrc
445 :group 'gnus-newsrc
448 (defcustom gnus-group-mode-hook nil
449 "Hook for Gnus group mode."
450 :group 'gnus-group-various
456 :group 'gnus-newsrc
480 (defvar gnus-group-line-format)
484 (defun gnus-read-init-file (&optional inhibit-next)
489 (setq gnus-init-inhibit inhibit-next)
504 prefixes prefix start ans group starts)
529 (setq group (car groups))))
530 (push group gnus-killed-list)
531 (gnus-sethash group group gnus-killed-hashtb)
537 (setq group (car groups))))
538 (gnus-sethash group group gnus-killed-hashtb)
544 (setq group (car groups))
545 (push group gnus-killed-list)
546 (gnus-sethash group group gnus-killed-hashtb)
554 (setq group (car groups))
557 (gnus-sethash group group gnus-killed-hashtb))
560 (setq group (car groups))
561 (push group gnus-killed-list)
562 (gnus-sethash group group gnus-killed-hashtb)
565 (push group gnus-killed-list)
566 (gnus-sethash group group gnus-killed-hashtb)))
605 (defun gnus-subscribe-interactively (group)
609 (if (gnus-y-or-n-p (format "Subscribe new newsgroup %s? " group))
610 (gnus-subscribe-hierarchically group)
611 (push group gnus-killed-list)))
613 (defun gnus-subscribe-zombies (group)
614 "Make the new GROUP into a zombie group."
615 (push group gnus-zombie-list))
617 (defun gnus-subscribe-killed (group)
618 "Make the new GROUP a killed group."
619 (push group gnus-killed-list))
621 (defun gnus-subscribe-newsgroup (newsgroup &optional next)
627 ;; We subscribe the group by changing its level to `subscribed'.
628 (gnus-group-change-level
630 gnus-level-killed (gnus-gethash (or next "dummy.group")
648 (defvar gnus-group-list-mode)
649 (defvar gnus-group-mark-positions)
692 gnus-group-list-mode nil
694 gnus-group-mark-positions nil
719 "Read network news.
729 (make-local-variable 'gnus-group-use-permanent-levels)
730 (setq gnus-group-use-permanent-levels val)))
733 "Read network news.
741 (switch-to-buffer gnus-group-buffer)
742 (gnus-group-get-new-news
745 (max (car gnus-group-list-mode) arg))))
771 (gnus-start-news-server (and arg (not level))))))
774 (gnus-group-quit)
793 (gnus-request-create-group "queue" '(nndraft "")))
794 (gnus-request-create-group "drafts" '(nndraft ""))
795 (gnus-setup-news nil level dont-connect)
796 (gnus-run-hooks 'gnus-setup-news-hook)
798 ;; Generate the group buffer.
799 (gnus-group-list-groups level)
800 (gnus-group-first-unread-group)
801 (gnus-configure-windows 'group)
802 (gnus-group-set-mode-line)
806 "Make sure the draft group exists."
807 (gnus-request-create-group "drafts" '(nndraft ""))
809 (gnus-message 3 "Subscribing drafts group")
811 (gnus-subscribe-group "nndraft:drafts" nil '(nndraft ""))))
812 (unless (equal (gnus-group-get-parameter "nndraft:drafts" 'gnus-dummy t)
814 (gnus-message 3 "Setting up drafts group")
815 (gnus-group-set-parameter
852 (set-buffer gnus-group-buffer)
853 (gnus-group-set-mode-line))
944 (defun gnus-setup-news (&optional rawfile level dont-connect)
945 "Setup news information.
947 If LEVEL is non-nil, the news will be set up at level LEVEL."
955 ;; Clear some variables to re-initialize news information.
1029 (when (and (boundp 'gnus-group-line-format)
1030 (stringp gnus-group-line-format)
1032 (string-match "%[-,0-9]*D" gnus-group-line-format))
1063 ;; Find the number of unread articles in each non-dead group.
1067 (defun gnus-call-subscribe-functions (method group)
1072 (funcall method group))
1076 (if (funcall func group)
1080 (gnus-subscribe-zombies group)))
1112 group new-newsgroups)
1123 (if (or (null (setq group (symbol-name sym)))
1126 (gnus-gethash group gnus-killed-hashtb)
1127 (gnus-gethash group gnus-newsrc-hashtb))
1129 (let ((do-sub (gnus-matches-options-n group)))
1133 (gnus-sethash group group gnus-killed-hashtb)
1135 gnus-subscribe-options-newsgroup-method group))
1140 (gnus-sethash group group gnus-killed-hashtb)
1142 (push group new-newsgroups)
1144 gnus-subscribe-newsgroup-method group)))))))
1153 (defun gnus-matches-options-n (group)
1154 ;; Returns `subscribe' if the group is to be unconditionally
1156 ;; no match for the group.
1161 (string-match gnus-options-subscribe group))
1164 (string-match gnus-auto-subscribed-groups group))
1167 (string-match gnus-options-not-subscribe group))
1176 (not (string-match (caar regs) group)))
1192 group new-newsgroups got-new method hashtb
1211 (lambda (group-sym)
1212 (if (or (null (setq group (symbol-name group-sym)))
1213 (not (boundp group-sym))
1214 (null (symbol-value group-sym))
1215 (gnus-gethash group gnus-newsrc-hashtb)
1216 (member group gnus-zombie-list)
1217 (member group gnus-killed-list))
1218 ;; The group is already known.
1220 ;; Make this group active.
1221 (when (symbol-value group-sym)
1222 (gnus-set-active group (symbol-value group-sym)))
1224 (let ((do-sub (gnus-matches-options-n group)))
1228 (gnus-sethash group group gnus-killed-hashtb)
1230 gnus-subscribe-options-newsgroup-method group))
1235 (gnus-sethash group group gnus-killed-hashtb)
1237 (push group new-newsgroups)
1239 gnus-subscribe-newsgroup-method group)))))))
1269 group)
1274 (when (setq group (symbol-name sym))
1275 (let ((do-sub (gnus-matches-options-n group)))
1278 (gnus-sethash group group gnus-killed-hashtb)
1280 gnus-subscribe-options-newsgroup-method group))
1284 (push group gnus-killed-list))))))
1286 (dolist (group groups)
1288 (when (gnus-active group)
1289 (gnus-group-change-level
1290 group gnus-level-default-subscribed gnus-level-killed)))
1292 (set-buffer gnus-group-buffer)
1293 ;; Don't error if the group already exists. This happens when a
1295 (gnus-group-make-help-group t))
1299 (defun gnus-subscribe-group (group &optional previous method)
1301 (gnus-group-change-level
1303 (list t group gnus-level-default-subscribed nil nil method)
1304 group)
1308 ;; `gnus-group-change-level' is the fundamental function for changing
1311 ;; again, which subscribes/unsubscribes a group, which is equally
1312 ;; trivial. Changing from 1-7 to 8-9 means that you kill a group, and
1313 ;; from 8-9 to 1-7 means that you remove the group from the list of
1321 ;; LEVEL is the new level of the group, OLDLEVEL is the old level and
1322 ;; PREVIOUS is the group (in hashtb entry format) to insert this group
1324 (defun gnus-group-change-level (entry level &optional oldlevel
1326 (let (group info active num)
1329 (if fromkilled (setq group (nth 1 entry))
1330 (setq group (car (nth 2 entry))))
1331 (setq group entry))
1344 (gnus-gethash group gnus-newsrc-hashtb))
1345 ;; We are trying to subscribe a group that is already
1349 (unless (gnus-ephemeral-group-p group)
1351 (format "(gnus-group-change-level %S %S %S %S %S)"
1352 group level oldlevel (car (nth 2 previous)) fromkilled)))
1355 ;; If the group was killed, we remove it from the killed or zombie
1361 (setq gnus-zombie-list (delete group gnus-zombie-list))
1362 (setq gnus-killed-list (delete group gnus-killed-list)))
1379 (gnus-sethash group nil gnus-newsrc-hashtb)
1382 (unless (gnus-group-foreign-p group)
1384 (push group gnus-zombie-list)
1387 (unintern group gnus-active-hashtb)
1389 (push group gnus-killed-list)))))
1402 (setq active (gnus-active group))
1409 (gnus-group-method group)))))
1411 (setq info (list group level nil nil method))
1412 (setq info (list group level nil)))))
1423 (gnus-sethash group (cons num (cdr previous))
1426 (gnus-sethash group (cons num previous)
1432 "(gnus-group-set-info '%S)" info)))))
1433 (when gnus-group-change-level-function
1434 (funcall gnus-group-change-level-function
1435 group level oldlevel previous)))))
1439 (gnus-group-change-level
1447 bogus group entry info)
1455 group (gnus-info-group info))
1456 (unless (or (gnus-active group) ; Active
1461 (push group bogus)))
1464 "Remove bogus group %s? "
1465 (lambda (group)
1468 (when (setq entry (gnus-gethash group gnus-newsrc-hashtb))
1469 (gnus-group-change-level entry gnus-level-killed)
1470 (setq gnus-killed-list (delete group gnus-killed-list))))
1471 bogus '("group" "groups" "remove"))
1472 (while (setq group (pop bogus))
1475 (when (setq entry (gnus-gethash group gnus-newsrc-hashtb))
1476 (gnus-group-change-level entry gnus-level-killed)
1477 (setq gnus-killed-list (delete group gnus-killed-list)))))
1485 (unless (gnus-active (setq group (pop killed)))
1486 ;; The group is bogus.
1489 (delete group (symbol-value (car dead-lists))))))
1506 (defun gnus-cache-possibly-alter-active (group active)
1509 (let ((cache-active (gnus-gethash group gnus-cache-active-hashtb)))
1516 (defun gnus-activate-group (group &optional scan dont-check method)
1517 "Check whether a group has been activated or not.
1518 If SCAN, request a scan of that group as well."
1519 (let ((method (or method (inline (gnus-find-method-for-group group))))
1523 ;; continue if a group is so out-there that it reports bugs
1528 (gnus-request-scan group method))
1531 (inline (gnus-request-group group dont-check method))
1533 (inline (gnus-request-group group dont-check method))
1536 (message "Quit activating %s" group)
1540 ;; If there are no articles in the group, the GROUP
1543 ;; for the group.
1546 (gnus-active group))
1547 (gnus-active group)
1552 group active)))
1556 (gnus-agent-possibly-alter-active group active))
1558 (gnus-set-active group active)
1562 (defun gnus-get-unread-articles-in-group (info active &optional update)
1564 ;; Allow the backend to update the info in the group.
1567 info (inline (gnus-find-method-for-group
1568 (gnus-info-group info)))))
1569 (gnus-activate-group (gnus-info-group info) nil t))
1574 ;; These checks are present in gnus-activate-group but skipped
1580 (gnus-info-group info) active)))
1584 (gnus-agent-possibly-alter-active (gnus-info-group info) active info))
1588 ;; number to the group hash table entry.
1653 (gnus-gethash (gnus-info-group info) gnus-newsrc-hashtb))
1654 (setcar (gnus-gethash (gnus-info-group info) gnus-newsrc-hashtb) num))
1658 ;; and compute how many unread articles there are in each group.
1674 scanned-methods info group active method retrieve-groups cmethod
1676 (gnus-message 6 "Checking new news...")
1679 (setq active (gnus-active (setq group (gnus-info-group
1683 ;; they can't be checked (for instance, if the news server can't
1689 ;; >0 for an active group with messages
1690 ;; 0 for an active group with no unread messages
1715 (setq active (gnus-activate-group group 'scan)))
1718 (gnus-agent-save-group-info
1719 method (gnus-group-real-name group) active))
1720 (unless (inline (gnus-virtual-group-p group))
1721 (inline (gnus-close-group group)))
1731 (if (gnus-check-backend-function 'retrieve-groups group)
1733 ;; the group onto retrievegroups for later checking
1736 (cons group (cdr (assoc method retrieve-groups))))
1737 (push (list method group) retrieve-groups))
1739 ;; on the group, so we must perform a scan for every group
1752 (setq active (gnus-activate-group group))
1753 (setq active (gnus-activate-group group 'scan))
1756 (gnus-close-group group)))))
1758 ;; Get the number of unread articles in the group.
1764 (inline (gnus-get-unread-articles-in-group info active t)))
1766 ;; The group couldn't be reached, so we nix out the number of
1768 (gnus-set-active group nil)
1769 (let ((tmp (gnus-gethash group gnus-newsrc-hashtb)))
1774 ;; and fetch a partial active file and use it to find new news.
1783 (mapcar (lambda (group) (gnus-group-real-name group)) groups)
1785 (dolist (group groups)
1787 ((setq active (gnus-active (gnus-info-group
1788 (setq info (gnus-get-info group)))))
1789 (inline (gnus-get-unread-articles-in-group info active t)))
1791 ;; The group couldn't be reached, so we nix out the number of
1793 (gnus-set-active group nil)
1794 (setcar (gnus-gethash group gnus-newsrc-hashtb) t)))))))
1796 (gnus-message 6 "Checking new news...done")))
1808 "dummy.group")
1810 (cons (list "dummy.group" 0 nil) alist)))))
1838 ;; Parse the result we got from `gnus-request-group'.
1844 (defun gnus-make-articles-unread (group articles)
1846 (let* ((info (nth 2 (or (gnus-gethash group gnus-newsrc-hashtb)
1847 (gnus-gethash (gnus-group-real-name group)
1850 news article)
1854 (push article news)))
1855 (when news
1856 ;; Enter this list into the group info.
1858 info (gnus-remove-from-range (gnus-info-read info) (nreverse news)))
1861 (gnus-get-unread-articles-in-group info (gnus-active group))
1863 ;; Insert the change into the group buffer and the dribble file.
1864 (gnus-group-update-group group t))))
1866 (defun gnus-make-ascending-articles-unread (group articles)
1868 (let* ((entry (or (gnus-gethash group gnus-newsrc-hashtb)
1869 (gnus-gethash (gnus-group-real-name group)
1877 (let ((article (pop articles))) ; get the next article to remove from ranges
1913 ;; next article
1925 ;; Enter this list into the group info.
1929 (gnus-get-unread-articles-in-group info (gnus-active group))
1931 ;; Insert the change into the group buffer and the dribble file.
1932 (gnus-group-update-group group t))))
1958 (group (symbol-name sym)))
1959 (if (or (null group)
1960 (gnus-gethash group gnus-killed-hashtb)
1961 (gnus-gethash group gnus-newsrc-hashtb))
1963 (let ((do-sub (gnus-matches-options-n group)))
1967 (push group gnus-killed-list)
1968 (gnus-sethash group group gnus-killed-hashtb))))))
1974 (gnus-group-set-mode-line)
2030 (gnus-find-method-for-group
2031 (gnus-info-group info) info))
2033 (push (gnus-group-real-name (gnus-info-group info))
2090 ;; Make the group names readable as a lisp expression even if they
2101 ;; group prefix in front of the group names.
2105 (let ((prefix (gnus-group-prefixed-name "" method)))
2115 (let (group max min)
2120 ;; group gets set to a symbol interned in the hash table
2122 (setq group (let ((obarray hashtb)) (read cur)))
2123 ;; ### The extended group name scheme makes
2125 (when (stringp group)
2126 (setq group (intern group hashtb)))
2136 (set group (cons min max))
2137 ;; if group is moderated, stick in moderation table
2141 (gnus-sethash (symbol-name group) t
2143 (set group nil)))
2145 (and group
2146 (symbolp group)
2147 (set group nil))
2168 (gnus-group-prefixed-name "" method))))
2183 (let (min max opoint group)
2196 (error (and group (symbolp group) (set group nil))))
2198 (let (min max group)
2205 (set (setq group (let ((obarray hashtb)) (read cur)))
2207 (error (and group (symbolp group) (set group nil))))
2399 (let (newsrc killed marked group m info)
2410 (while (setq group (pop newsrc))
2411 (if (setq info (gnus-get-info (car group)))
2413 (gnus-info-set-read info (cddr group))
2415 info (if (nth 1 group) gnus-level-default-subscribed
2419 (list (car group)
2420 (if (nth 1 group) gnus-level-default-subscribed
2422 (cddr group)))
2425 (when (setq m (assoc (car group) marked))
2470 group subscribed options-symbol newsrc Options-symbol
2491 ;; Now, the symbol we have read is either `options' or a group
2504 ;; Options may continue on the next line.
2515 ;; It was a group name.
2517 group (symbol-name symbol)
2539 ;; If the next character is a dash, then this is a range.
2560 ;; If the next char in ?\n, then we have reached the end
2572 (setq group nil)
2585 (when group
2586 (let ((info (gnus-get-info group))
2604 ;; This is a new group.
2605 (setq info (list group
2623 ;; gnus-newsrc-alist to the (native) group that precedes them.
2628 (or (null (nth 4 (car rc))) ; It's a native group.
2803 (gnus-group-set-mode-line)))))
2839 ;; Peel off the "dummy" group.
2882 (insert (gnus-info-group info)
3003 group)
3012 (gnus-sethash (gnus-group-prefixed-name "" method) "Has read"
3035 ;; group prefix in front of the group names.
3041 (let ((prefix (gnus-group-prefixed-name "" method)))
3048 ;; If we get an error, we set group to 0, which is not a
3050 (setq group
3059 (when (symbolp group)
3062 (name (symbol-name group))
3064 (or (gnus-group-name-charset method name)
3070 (set group str)))
3075 (defun gnus-group-get-description (group)
3076 "Get the description of a group by sending XGTITLE to the server."
3077 (when (gnus-request-group-description group)
3107 (defun gnus-fixup-nnimap-unread-after-getting-new-news ()
3108 (let (server group info)
3111 (when (and (setq group (symbol-name sym))
3112 (gnus-group-entry group)
3114 (gnus-sethash group (cons (nth 2 info) (cdr (gnus-group-entry group)))