Function: erc-join-channel
erc-join-channel is an interactive and byte-compiled function defined
in erc.el.gz.
Signature
(erc-join-channel CHANNEL &optional KEY)
Documentation
Join CHANNEL.
If point is at the beginning of a channel name, use that as default.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/erc/erc.el.gz
(defun erc-join-channel (channel &optional key)
"Join CHANNEL.
If `point' is at the beginning of a channel name, use that as default."
(interactive
(list
(let ((chnl (if (looking-at "\\([&#+!][^ \n]+\\)") (match-string 1) ""))
(table (when (erc-server-buffer-live-p)
(set-buffer (process-buffer erc-server-process))
erc-channel-list)))
(completing-read (format-prompt "Join channel" chnl)
table nil nil nil nil chnl))
(when (or current-prefix-arg erc-prompt-for-channel-key)
(read-string "Channel key (RET for none): "))))
(erc-cmd-JOIN channel (when (>= (length key) 1) key)))