How to run

1. You need python3

So... install python3 if you haven't. 🙃

2. You need all requires package

So... Run:

pip3 install -r requirements.txt

3. You need to configure discord bot token

How to do that is described here: writebots.com. It's the most important page: Discord Developer Panel.

The generated token save in token.txt file in the root directory (next to main.py).

4. Run 🙂

For example by:

python3 main.py

5. Invite and tag bot on your server

It's also described here: writebots.com.

6. The help

To get the help message send by discord:

.help

or

.help <name of command>

(. is the default bot prefix)

Good luck!

Bonus for Linux users

One of the way to run bot in the background of the OS. (It's written by Ubuntu 20.04 user.)

  1. Clone the repo in to /var directory.
  2. Create www user with correct permissions to read and execute existing files and create files in files and config directories.
  3. Create a service config file /etc/systemd/system/discordbot.service, with that content:
[Unit]
Description=Discord BOT service
After=network.target
StartLimitIntervalSec=0

[Service]
Type=simple
Restart=always
RestartSec=1
User=www
WorkingDirectory=/var/Collector_bot
ExecStart=python3 /var/Collector_bot/main.py
SyslogIdentifier=DiscorBOT

[Install]
WantedBy=multi-user.target
  1. Run commands:
sudo systemctl enable discordbot.service
sudo systemctl start discordbot.service
sudo systemctl status discordbot.service
  1. And if you want to stop the bot:
sudo systemctl stop discordbot.service