[https://libera.chat/guides/usermodes This guide] from Libera Chat lists the available modes on the network.

Typical <code>/topic</code> pattern optimizing for newbies (link first):

<pre>
/topic See http://emacswiki.org/emacs/EmacsChannel for tips, code of conduct | Go ahead and ask your Emacs question | Treat people with respect. No sexism, racism, homophobia, or discrimination of any kind. | No public logging
</pre>

Typical <code>/topic</code> pattern optimizing for the amusement of regulars (quote first):

<pre>
/topic quote | See http://emacswiki.org/emacs/EmacsChannel for tips, code of conduct | Go ahead and ask your Emacs question | Treat people with respect. No sexism, racism, homophobia, or discrimination of any kind. | No public logging
</pre>

== Dealing with violations of the code of conduct ==

* Please give some warning first. 
* Try to focus on correcting behaviour rather than judging people, and redirect people to better alternative behaviours. Distinguish between "That's not welcome here. Do this instead." and "You're not welcome here."
* Give people the benefit of the doubt. Don't assume that they're pretending to be offended or that they're trolling; they may have a valid concern.
* See [[#ERCCommands|ERC Commands]] for functions to make managing users easier.

Here are some options:

=== Quiet the user ===

They can stay in channel, but they can't say anything.

<pre>
/mode #emacs +q nick
</pre>

=== Kick the user ===

<pre>
/kick nick
</pre>

=== Ban returning rude people by hostname ===

<pre>
/mode #emacs +b *!user@hostname
</pre>


== IRC commands ==

=== See access list ===

<pre>
/msg ChanServ access #emacs list
</pre>

Check what the levels mean:

<pre>
/msg chanserv level #emacs list
</pre>

=== Modify access list ===

Add only the nicks of identified users.

<pre>
/msg ChanServ access #emacs add noob 10
</pre>

[:ERCCommands]
== ERC Commands ==

You may also want to check out https://github.com/jwiegley/dot-emacs/blob/master/lisp/erc-macros.el for ideas.

=== Easy op/deop ===

{{{
(defun erc-cmd-OPME ()
  "Request chanserv to op me."
  (erc-message "PRIVMSG"
               (format "chanserv op %s %s"
                       (erc-default-target)
                       (erc-current-nick)) nil))

(defun erc-cmd-DEOPME ()
  "Deop myself from current channel."
  (erc-cmd-DEOP (format "%s" (erc-current-nick))))
}}}

=== Ban, kickban ===
{{{
(defun erc-cmd-BAN (nick)
  (let* ((chan (erc-default-target))
         (who (erc-get-server-user nick))
         (host (erc-server-user-host who))
         (user (erc-server-user-login who)))
    (erc-send-command (format "MODE %s +b *!%s@%s" chan user host))))

(defun erc-cmd-KICKBAN (nick &rest reason)
  (setq reason (mapconcat #'identity reason " "))
  (and (string= reason "")
       (setq reason nil))
  (erc-cmd-BAN nick)
  (erc-send-command (format "KICK %s %s %s"
                            (erc-default-target)
                            nick
                            (or reason
                                "Kicked (kickban)"))))
}}}

[:ERCQuiet]
=== Make people quiet ===

They can stay in channel, but they can't say anything. [https://gist.github.com/jwiegley/1af912d0833206125afa Source]
{{{
(defun erc-cmd-QUIET (nick)
  (erc-cmd-OPME)
  (sleep-for 0 250)
  (erc-send-command (format "QUIET %s %s"
                            (erc-default-target)
                            nick))
  (sleep-for 0 250)
  (erc-cmd-DEOPME))
}}}

=== Kick/ban based on IP address  ===

[https://gist.github.com/jwiegley/e1b92259c3335124d3fc Source]
{{{
(defun erc-cmd-KICKBANIP (nick &rest reason)
  (setq reason (mapconcat #'identity reason " "))
  (and (string= reason "")
       (setq reason nil))
  (erc-cmd-OPME)
  (sleep-for 0 250)
  (erc-cmd-BAN nick nil t)
  (erc-send-command (format "KICK %s %s %s"
                            (erc-default-target)
                            nick
                            (or reason
                                "Kicked (kickbanip)")))
  (sleep-for 0 250)
  (erc-cmd-DEOPME))
}}}
== Circe commands ==

https://github.com/jorgenschaefer/Config/blob/master/emacs.el#L886-L914

{{{
(defun circe-command-AKICK (args)
  "Kick a user from the current channel using ChanServ.

Example uses:

/akick someidiot Get lost
- Kick someidiot with the message 'Get lost' for 30 minutes
/akick someidiot !T 15 Try again later
- Kick someidiot with the message 'Try again later' for 15 minutes"
    (cond
     ((string-match "!T" args)
      (circe-command-MSG "ChanServ"
                         (format "AKICK %s ADD %s"
                                 circe-chat-target
                                 args)))
     ((string-match "^ *\\([^ ]+\\) \\([0-9]+\\) \\(.*\\)" args)
      (circe-command-MSG "ChanServ"
                         (format "AKICK %s ADD %s !T %s %s"
                                 circe-chat-target
                                 (match-string 1 args)
                                 (match-string 2 args)
                                 (match-string 3 args))))
     ((string-match "^ *\\([^ ]+\\) \\(.*\\)" args)
      (circe-command-MSG "ChanServ"
                         (format "AKICK %s ADD %s !T %s %s"
                                 circe-chat-target
                                 (match-string 1 args)
                                 "30"
                                 (match-string 2 args))))))
}}}
----

EmacsChannel
