This is a discord bot for Foothill College's CS Club's Summer 2020 Hackathon 💬. It supports tracking projects, which are called "hacks".
The following are the commands that all users can use:
List all the hacks.
Ex. hacks add "A very cool project" @cooldude
Add a hack! Make sure to specify a description (quote with " if more than one word) and at least one user with an @mention
.
Ex. hacks update 4 "A very cool project"
Ex. hacks update 12 "Not sure what this is.." @dude @coder
Update a hack. A new description is required, and an updated list of members is optional.
Ex. hacks remove 6
Remove a hack. Tip: use hacks list
to list all the hacks with their index.
Ex. hacks link 6 https://github.com/FoothillCSClub/hackbot
Add a project link to a hack. A URL is required.
Ex. hacks unlink 6
Remove a project link from a hack.
Ex. hacks send #announcements
Send the hackathon info message and the list of hacks into the specified channel. The last sent messages by this command are tracked and are automatically updated when someone modifies the list of hacks.
Ex. hacks delete #announcements
Delete the last tracked info messages from a channel (sent by hacks send
), if they exist.
Install discord.py
and tinydb
through pip.
Set an environment variable DISCORD_API_KEY
to your Discord bot API key, and then run the following:
python3 bot.py
On UNIX systems, you can also run:
DISCORD_API_KEY="mykey" python3 bot.py
Warning: if you do this, then your API key will be in your shell command history!