GithubHelp home page GithubHelp logo

jasonetco / camperbot Goto Github PK

View Code? Open in Web Editor NEW

This project forked from freecodecamp-montreal/camperbot

0.0 2.0 0.0 114 KB

:robot: discord bot made for freeCodeCamp Montreal :fire:

Home Page: https://sirmerr.github.io/camperbot/

License: MIT License

JavaScript 100.00%

camperbot's Introduction

camperbot ⛺️πŸ”₯πŸ€–

Build Status codecov open source Discord

freeCodeCamp Montreal discord bot, using discord.js. Gives people marshmellows.

Installation

Prerequisites

To run this you need to have

  • Node 8
  • yarn or npm
  • cloned this repo
  • ❀️

Make a discord app

  1. Create a new discord app if you don't have one.

  2. Make it a bot user.

  3. Take note of the Client ID, Client Secret and Token (in the Bot section) Create a .env file in your cloned repo. Put the contents of .env.example in it and replace with your saved tokens (first three)

    CLIENT_ID=
    CLIENT_SECRET=
    BOT_TOKEN=
    
    # Postgres DB
    DB_HOST=
    DB_NAME=
    DB_USER=
    DB_PORT=
    DB_PASSWORD=

Local DB

Note: You don't need this if you are not working on commands that rely on a database. Additionally, we use PostgreSQL.

Set up your local database and fill the rest of your .env with its credentials.

Then run:

yarn migrate-up

You should see something along the lines of this:

$ yarn build &&NODE_PATH=build node -r  libs/dotenv node_modules/.bin/db-migrate up
$ babel src -d build
src/app.js -> build/app.js
...
received data: CREATE SCHEMA IF NOT EXISTS public;

CREATE TABLE accounts(
...

There should be no error message, and once you check your database you'll see it has tables in it now πŸŽ‰.

Usage

Install dependencies

yarn

Run

yarn start

or, to reload of src file changes:

yarn start:watch

Commands

At this time, many commands are intended for development purposes

For a full, detailed list of commands, go here: https://sirmerr.github.io/camperbot/#/camperbot/commands

  • !ping: Responds with pong!
  • !help | !h: Either shows a help for a single command, or DMs you a help link if no parameters are specified.
  • !knowme: Checks if you are in the accounts table, and adds you if you're not
  • !repopulate: [FireStarter] Add every member of the server/guild who isn't in the accounts table
  • !marshmellow [@username] | !mm [@username]: Gives someone a marshmellow for being helpful (you can give marshmellows to multiple people at a time (ex: !marshmellow @username1 @username2)
  • !mine: Shows whoever triggered this command how many marshmellows they have

Upcoming Features

  • !camping: Give people a Camper role after having been part of the discord for a month (they trigger it)
  • People can ask questions via it (via DM or in chat), it will respond with similar questions/answers and also notify mentors if we want it to (+ would add it to our docs website so others can see)
  • !nextevent -> responds with the next event planned (facebook link or something)
  • !iknow [comma separated stuff] -> Add a self-summary of what languages/techs you know
  • !theyknow @user -> Check what languages/techs a user knows
  • give points to people that react/respond to questions/peer-review

camperbot's People

Contributors

tiffafoo avatar

Watchers

 avatar  avatar

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.