Skip to content
This repository has been archived by the owner on Oct 15, 2021. It is now read-only.

Releases: Sirspam/Discord.py-Bot-Template

Discord.py Bot Template v0.0.1

01 Jul 12:34
Compare
Choose a tag to compare

Setting up

Requirements:

Install the libraries defined in requirements.txt. These can all be done via pip.
This file isn't needed for the bot to run, although it's been included within this release to preserve the lib versions. The txt file can be safely deleted.

.env file:

  • AssignTOKEN your bot's token, which can be got at the Discord Dev Portal.
  • Assign DEFAULT_PREFIX a string for the prefix you would like your bot to use. This is useful so multiple bots on the same token can be running with different prefixes, say for testing purposes.
  • If you're going to make a GitHub repository for your bot, add .env to gitignore. This is so your token isn't accidentally committed and made viewable for the whole world to see.

error_handler.py:

On line 67 there's a line which gets a channel within my personal discord server, This is done so that an unhandled error can be dumped there. Either replace the channel ID with the ID for a channel in your own server, or just remove the code from lines 62 to 72.