Giter Club home page Giter Club logo

motd-bot's Introduction

MOTD-Bot

Discord bot aimed towards collecting user suggested films to suggest a new movie.

About

The bot collects IMDB and Letterboxd film suggestions from users and recommends a random film from the database.

  • Film collection:

alt text

  • Movie suggestion:

alt text

  • Random suggestion:

alt text

Install Prerequisites

Install Git

  1. Download Git for your system from the Git website.
  2. Run the installer file and follow the instructions.
  3. Verify your git install by opening a terminal and typing git --version.
  4. Done for now! You can continue to the next section.

Install Node.js and NPM

  1. Download the current Node.js and NPM bundle for your system from the Node.js website.
  2. Run the installer file and follow the instructions.
  3. Verify your Node.js and NPM install by typing node -v and npm -v, respectively.
  4. Done for now! You can continue to the next section.

Install MySQL

  1. Download the MySQL Community server from the MySQL website.
  2. Run the installer file and follow the instructions.
  3. Copy the temp password at the last prompt, you will need this.
  4. Run the command mysql -u root -p and enter the password you copied from the installer.
  5. Once logged in to the root user, run CREATE USER 'your_username' IDENTIFIED BY 'your_password';

Setup

  1. Clone the repository to your machine using git clone https://github.com/jnwarner/motd-bot.git
  2. Open the directory in a terminal and use the command npm install to install dependencies.
  3. Log into the MySQL account made when installing mysql using the command mysql -u your_username -p
  4. Run the db.sql file using mysql -u your_username -p < /path/to/db.sql, creating the tables for the bot.
  5. Grant permissions to user using the command GRANT PRIVILEGES ON movies.* TO 'your_username'@'localhost' IDENTIFIED BY 'your_password';
  6. Insert the necessary data in a file named tokens.json (reference can be found in tokens.example.json)
  7. Done! You can start your bot using node index.js or use a process management service such as PM2 to run the bot!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.