Git Product home page Git Product logo

umass-events-discord-bot's Introduction

UMass Events Bot

builds.sr.ht status

A Discord and Telegram bot written in Rust to enable easy access to a variety of University of Massachusetts, Amherst services. Currently, it provides the ability to search across the dining halls to check which foods are present on a given day, as well as information on room availability to ease studying.

For the issue tracker, see https://todo.sr.ht/~gbear605/umass_bot

Usage

To add it to your server, go to this link and authorize the bot.

Development

The program requires a bot token to connect to Discord or Telegram. It does this using private token files (discord_token and telegram_token respectively) which can be acquired from Discord and Telegram.

Crosscompiling for Linux

Using: https://github.com/emk/rust-musl-builder

Docker needs to be installed.

  1. Set the alias for the builder:

alias rust-musl-builder='docker run --rm -it -v cargo-git:/home/rust/.cargo/git -v cargo-registry:/home/rust/.cargo/registry -v "$(pwd)":/home/rust/src ekidd/rust-musl-builder:nightly-2019-06-08'

  1. Start the Docker daemon (if it isn't already running)

  2. Set up the file cache: (speeds up build time)

rust-musl-builder sudo chown -R rust:rust /home/rust/.cargo/git /home/rust/.cargo/registry

  1. Build: (this will download a linux docker image to compile in if it is not already downloaded)

Expect the build step to initially take about fifteen minutes, then to take a while (roughly a minute) each time after the first.

rust-musl-builder cargo build --bin telegram_client --release rust-musl-builder cargo build --bin discord_client --release rust-musl-builder cargo build --bin server --release

To update the container, run docker pull ekidd/rust-musl-builder:nightly-2019-06-08

The built files will be in target/x86_64-unknown-linux-musl/release

umass-events-discord-bot's People

Contributors

gbear605 avatar

Stargazers

 avatar  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.