- Place Q-Killer script in a new directory
- Place your Slack bots token on line 17 of
qkiller.py
- Fill out the info in
auth.json
(see "Creating a Script Application below) - Edit the message to deliver and the channel name in
settings.json
Note - if you want to mention all active users, you must use<!here>
instead of@here
. Same applies for@channel
mentions - use<!channel>
instead. - OPTIONAL: Adjust alert parameter (
NUM_TO_ALERT
) on line 21. This decides how many reports must be in queue before an alert is triggered - Start the script with
nohup
by runningnohup python3 qkiller.py &
(Linux)
If you only have 1 version of python installed, just use python
instead of python3
when starting the script.
WINDOWS - To run this script on a windows server or desktop, you can use pythonw
to run it in the background.
This script was made by /u/zebradolphin5 for the /r/GlobalOffensive mod team, to alert us in Slack if the modqueue reaches 15 or more items.
Use nohup
to run in the background and ignore the hangup signal. (See 'How to use' above)
To obtain a client ID and client secret, login to the Reddit account that will be using the script, and go to preferences>apps.
Click on "Create a new app" (may say "Create another app") and SELECT THE 'Script' TYPE (not 'web' or 'installed'. Name/description
can be whatever. You can leave the about URL blank, but you still must provide a redirect URI even though it's not needed for a
script application. For that, you can just put http://localhost/
. The string at the top left (underneath what should say personal
use script) will be your client_ID. Client secret is listed next to the 'Secret' field.