Mho is a Discord bot for engineering students at UofT.
Requires:
This bot uses Discord.js and the Sapphire Framework
/course [course code] // displays course description from https://engineering.calendar.utoronto.ca/
/timetable [session] [course code] // displays course timetable information from https://undergrad.engineering.utoronto.ca/academics-registration/course-timetables/
/exam [course code] // displays exam schedule details from https://portal.engineering.utoronto.ca/sites/timetable/fes.aspxThis bot uses Redis for caching web requests, but it is not required. If you want caching, you can download Redis here, or with brew on Mac
Set BOT_TOKEN in a .env file within the root directory and run
npm i
node .
If you'd like to host this bot on a 24/7 basis, there are a multitude of services that offer some form of free hosting, such as Heroku or Google Cloud. You can also consider self-hosting, in which case using pm2 to daemonize your app and configure startup scripts is recommended.
Interested in contributing? Great! You can first open up an issue for what you want to add or fix to see if it is something that would be useful for the bot. Afterwards, you can fork this repo and start developing.
- The Discord.js guide provides great resources, and helps you code a bot from start to finish.
- There are a number of resources for learning Git. You can check out the official Git book, video tutorials from GitKraken, and an interactive Git branching guide.
- Use nodemon to facilitate testing changes.
- Use ESLint for code style and consistency. It makes it easier for all of us if things stay consistent.
- There are some VS Code snippets provided for commands, events and embeds.
- SQLite is used for data persistence. DB4S is a useful tool for viewing and editing SQLite database files.