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

Lines Matching refs:autojoin

1 ;;; erc-join.el --- autojoin channels on connect and reconnects
28 ;; This allows us to customize an `erc-autojoin-channels-alist'. As
39 (defgroup erc-autojoin nil
43 ;;;###autoload (autoload 'erc-autojoin-mode "erc-join" nil t)
44 (define-erc-module autojoin nil
45 "Makes ERC autojoin on connects and reconnects."
46 ((add-hook 'erc-after-connect 'erc-autojoin-channels)
47 (add-hook 'erc-server-JOIN-functions 'erc-autojoin-add)
48 (add-hook 'erc-server-PART-functions 'erc-autojoin-remove))
49 ((remove-hook 'erc-after-connect 'erc-autojoin-channels)
50 (remove-hook 'erc-server-JOIN-functions 'erc-autojoin-add)
51 (remove-hook 'erc-server-PART-functions 'erc-autojoin-remove)))
53 (defcustom erc-autojoin-channels-alist nil
54 "Alist of channels to autojoin on IRC networks.
65 :group 'erc-autojoin
71 (defcustom erc-autojoin-domain-only t
74 only b.c is used as the server for `erc-autojoin-channels-alist'.
77 :group 'erc-autojoin
80 (defun erc-autojoin-channels (server nick)
81 "Autojoin channels in `erc-autojoin-channels-alist'."
82 (dolist (l erc-autojoin-channels-alist)
87 (defun erc-autojoin-add (proc parsed)
88 "Add the channel being joined to `erc-autojoin-channels-alist'."
94 (when (and erc-autojoin-domain-only
97 (let ((elem (assoc server erc-autojoin-channels-alist)))
101 (setq erc-autojoin-channels-alist
103 erc-autojoin-channels-alist))))))
110 (defun erc-autojoin-remove (proc parsed)
111 "Remove the channel being left from `erc-autojoin-channels-alist'."
117 (when (and erc-autojoin-domain-only
120 (let ((elem (assoc server erc-autojoin-channels-alist)))
124 (setq erc-autojoin-channels-alist
125 (delete elem erc-autojoin-channels-alist)))))))