gist/irc/atheme/cstemplate

85 lines
3.0 KiB
Plaintext
Raw Normal View History

#!/usr/bin/env bash
2014-09-24 18:19:55 +02:00
# This script generates commands which can be copy-pasted to Atheme's
# ChanServ to set templates which can later be set with flags.
# With these templates, bots and ops are opped and (trusted) users are
# voiced. I am not fully sure where I took the word "users", but it's good
# enough.
2014-10-12 15:52:44 +02:00
## ChanServ settings
# Allows everyone to see ACL changes.
echo "/cs set $1 VERBOSE ON"
2014-10-12 15:52:44 +02:00
# Tell ChanServ to be on channel. Not needed for larger channels
echo "/cs set $1 GUARD ON"
2014-10-12 15:52:44 +02:00
# Adjusts ChanServ MLOCK
# This list should work with Charybdis and mostly with InspIRCd, g has
# different meaning there and won't be set.
# * n — no external messages, you must be on the channel to message it.
# * t — you must be hop or higher to change topic
2015-06-02 08:41:38 +02:00
# !* g — anyone can /invite
# * InspIRCd: +g blocks messages matching the given glob mask - if
# empty not set, I think
# * C — block CTCPs to channel
2015-06-02 08:41:38 +02:00
# !* A — InspIRCd: anyone can /invite
# * Charybdis: Admin-only, but this MLOCK does nothing to me, so I am
# * ignoring it.
# * T — InspIRCd: blocks notices from users who aren't at least HOP
#
# * i — invite-only
# * l — limit maximum number of people on the channel
# * k — key/password for joining the channel
# Other nice modes (not set by this script): Charybdis +rS / InspIRCd: +Rz
# (only identified, SSL users can join)
# InspIRCd: +M blocks messages from unidentified users.
# To remove MLOCK "/cs set #channel MLOCK"
2015-06-02 08:41:38 +02:00
# THIS DOES NOT SET MODES MARKED WITH ! AS THAT CAN BE DANGEROUS DEPENDING
# ON NETWORK! mlock +A on Charybdis with specific module prevents you from
2015-07-25 10:27:10 +02:00
# joining the channel
2015-06-02 08:41:38 +02:00
echo "/cs set $1 MLOCK +ntCT-ilk"
2014-10-12 15:52:44 +02:00
# Hide channel information from people who don't have +A
echo "/cs set $1 PRIVATE ON"
2014-10-12 15:52:44 +02:00
2014-10-25 20:43:00 +02:00
# Sync flags when they are changed
echo "/cs set $1 NOSYNC OFF"
2014-10-12 15:52:44 +02:00
# Allow only identified users to be opped
echo "/cs set $1 SECURE ON"
2014-10-12 15:52:44 +02:00
# Allow only users with +t flag to change topic
echo "/cs set $1 TOPICLOCK ON"
2014-10-12 15:52:44 +02:00
## ChanServ templates
2014-09-24 18:19:55 +02:00
# Channel founder who can do anything they want.
echo "/cs template $1 founder !+*F"
2014-09-24 18:19:55 +02:00
# Successor will get all flags in the end and if they cannot be trusted
# with them now, they really shouldn't be successor.
echo "/cs template $1 successor !+*S"
2014-09-24 18:19:55 +02:00
# Super op, be able to do everything with services
echo "/cs template $1 sop !+vVhHoOasirRftAe"
2014-09-24 18:19:55 +02:00
# Normal op, be able to invite, invite, kick, kickban, unban, change topic
echo "/cs template $1 op !+vVhHoOirtAe"
2014-09-24 18:19:55 +02:00
# Half op, be able to do everything else than kick other halfops & higher
echo "/cs template $1 hop !+vVhHirtAe"
2014-09-24 18:19:55 +02:00
# Network operator whom we want to have a little access so they can help
# with channel issues in case our own ops are away.
# Usually given to $OPER or staffer hostmask.
echo "/cs template $1 oper !+vhoirtAe"
2014-09-24 18:19:55 +02:00
# User who is just allowed to voice themselves and get into the channel
# unless they are banned.
echo "/cs template $1 user !+ViA"
2014-09-24 18:19:55 +02:00
# Permanent ban. Removes all flags and sets autokick.
2014-10-12 15:56:27 +02:00
echo "/cs template $1 ban !-*+b"
2015-02-10 05:31:32 +01:00
# Access, can only get in to (RESTRICTED) channel
echo "/cs template $1 access !-*+i"