From: ueno Date: Sat, 20 Sep 2003 00:55:04 +0000 (+0000) Subject: * riece-options.el (riece-startup-channel-list): Revive. X-Git-Tag: riece-0_1_2~7 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=e4f4be6b09a87a96b1e51033bef134af029e968e;p=elisp%2Friece.git * riece-options.el (riece-startup-channel-list): Revive. * riece-000.el (riece-handle-001-message): Process riece-startup-channel-list. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9b42166..81718f0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,9 @@ 2003-09-20 Daiki Ueno + * riece-options.el (riece-startup-channel-list): Revive. + * riece-000.el (riece-handle-001-message): Process + riece-startup-channel-list. + * riece-server.el (riece-open-server): Display "Logging in to XXX..." message. * riece-000.el (riece-handle-001-message): Clear "Logging in to diff --git a/lisp/riece-000.el b/lisp/riece-000.el index 9a442f2..2f7c713 100644 --- a/lisp/riece-000.el +++ b/lisp/riece-000.el @@ -49,6 +49,13 @@ (if (equal riece-server-name "") (message "Logging in to IRC server...done") (message "Logging in to %s...done" riece-server-name)) + (let ((channel-list riece-startup-channel-list)) + (while channel-list + (if (listp (car channel-list)) + (riece-command-join (car (car channel-list)) + (nth 1 (car channel-list))) + (riece-command-join (car channel-list))) + (setq channel-list (cdr channel-list)))) (run-hooks 'riece-after-login-hook)) (defun riece-handle-004-message (prefix number name string) diff --git a/lisp/riece-options.el b/lisp/riece-options.el index d40dedd..44dfc92 100644 --- a/lisp/riece-options.el +++ b/lisp/riece-options.el @@ -182,6 +182,12 @@ way is to put Riece variables on .emacs or file loaded from there." :type 'string :group 'riece-server) +(defcustom riece-startup-channel-list nil + "A list of channels to join automatically at startup." + :type '(repeat (choice (string :tag "Channel") + (list (string :tag "Channel") (string :tag "Key")))) + :group 'riece-channel) + (defcustom riece-retry-with-new-nickname nil "When nickname has already been in use, grow-tail automatically." :type 'boolean