Function: erc-cmd-KICK
erc-cmd-KICK is a byte-compiled function defined in erc.el.gz.
Signature
(erc-cmd-KICK TARGET &optional REASON-OR-NICK &rest REASONWORDS)
Documentation
Kick the user indicated in LINE from the current channel.
LINE has the format: "#CHANNEL NICK REASON" or "NICK REASON".
Source Code
;; Defined in /usr/src/emacs/lisp/erc/erc.el.gz
(defun erc-cmd-KICK (target &optional reason-or-nick &rest reasonwords)
"Kick the user indicated in LINE from the current channel.
LINE has the format: \"#CHANNEL NICK REASON\" or \"NICK REASON\"."
(let ((reasonstring (mapconcat #'identity reasonwords " ")))
(if (string= "" reasonstring)
(setq reasonstring (format "Kicked by %s" (erc-current-nick))))
(if (erc-channel-p target)
(let ((nick reason-or-nick))
(erc-log (format "cmd: KICK: %s/%s: %s" nick target reasonstring))
(erc-server-send (format "KICK %s %s :%s" target nick reasonstring)
nil target)
t)
(when target
(let ((ch (erc-default-target)))
(setq reasonstring (concat
(if reason-or-nick (concat reason-or-nick " "))
reasonstring))
(if ch
(progn
(erc-log
(format "cmd: KICK: %s/%s: %s" target ch reasonstring))
(erc-server-send
(format "KICK %s %s :%s" ch target reasonstring) nil ch))
(erc-display-message nil 'error (current-buffer)
'no-default-channel))
t)))))