GithubHelp home page GithubHelp logo

reddit-gitbot's Introduction

Reddit Gitbot

This is a Reddit bot built with PRAW to check Reddit comments for erroneous git commands.

Prerequisites

If you want to try out the bot locally, you only need to install PRAW. If the app is to be deployed directly to Heroku, all needed modules are described in the requirements.txt file.

Deployment

First steps

First you would probably want to create a new Reddit account for your bot.

  • Go to Reddit and create an account.
  • Login and go to Preferences > Apps and click "create another app..."
  • Type a name for your app and choose "script". Add a description and provide the "about" and "redirect" URIs.

Next, you will need to create a new heroku account if you don't have one already.

  • Go to Heroku and create an account.
  • Create a Heroku app.
  • Download and install Heroku CLI.
  • Open Bash or CMD and login to Heroku CLI $ heroku login.

Pre-deployment

  • Clone the current repository to your local storage.
  • Rename the folder name to anything you need.
  • Open the friendbot.py and hintbot.py files and add your Reddit user and app info.
  • Make changes to both of these files to suit your needs.

Deployment

  • Open Bash or CMD and cd to your project folder.
  • Change your remote to $ heroku git:remote -a your_heroku_app_name
  • Add a buildpack to Heroku so it can understand that this is a Python app. heroku buildpacks:set heroku/python
  • Commit your changes. git add ., git commit -m "Ready to be deployed".
  • Deploy your app by typing git push heroku master.

Post-deployment

  • Go to Heroku and go to you app administration.
  • Select "Resources" and press the pen button beside your dyno.
  • Change the slider to active and press confirm.
  • Press "More" on the top right corner and then "View Logs".
  • There should be a line State changed from starting to up, that means that your app is up and running.

reddit-gitbot's People

Contributors

visovsiouk avatar

Watchers

 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.