GithubHelp home page GithubHelp logo

isabella232 / rails-bot Goto Github PK

View Code? Open in Web Editor NEW

This project forked from rails/rails-bot

0.0 0.0 0.0 134 KB

Github hooks to provide an encouraging atmosphere for new contributors

Python 100.00%

rails-bot's Introduction

Highfive

GitHub hooks to provide an encouraging atmosphere for new contributors

See this bot in action: @rails-bot

Install

To install highfive you just need to execute the setup.py script or use pip directly. Both commands have to be executed from the directory where the setup.py script is located.

$ pip install -r requirements.txt
$ python setup.py install

or

$ pip install -r requirements.txt
$ pip install . # the dot is important ;)

Adding a Project

To make rails-highfive interact with a new repo, add a configuration file in highfive/configs, with a filename of the form reponame.json.

It should look like:

{
    "groups":{
        "all": ["@username", "@otheruser"],
        "subteamname": ["@subteammember", "@username"]
    },
    "dirs":{
        "dirname":  ["subteamname", "@anotheruser"]
    },
    "contributing": "http://project.tld/contributing_guide.html",
    "expected_branch": "develop"
}

The groups section allows you to alias lists of usernames. You should specify at least one user in the group "all"; others are optional.

The dirs section is where you map directories of the repo to users or groups who're eligible to review PRs affecting it. This section can be left blank.

contributing specifies the contribution guide link in the message which welcomes new contributors to the repository. If contributing is not present, the Rails contributing guide will be linked instead.

If PRs should be filed against a branch other than master, specify the correct destination in the expected_branch field. If expected_branch is left out, highfive will assume that PRs should be filed against master. The bot posts a warning on any PR that targets an unexpected branch.

Deploying

rails-highfive can be deployed on Heroku. You'll need to set up the following required environment variables:

  • GITHUB_USER: the bot's GitHub user
  • GITHUB_TOKEN: the bot's GitHub token
  • HOOK_SECRET: a secret string that is shared with the GitHub webhook setup

To set up a webhook on GitHub for testing your bot, use the following settings on a repo or org:

  • Content type: application/json
  • Secret: the same string you used in the HOOK_SECRET env var for your bot
  • Events:
    • Select Let me select individual events
    • Select Issues, Pull request review comment, Issue comment, Pull request

rails-bot's People

Contributors

ben0x539 avatar brodyholden avatar dideler avatar flaper87 avatar huonw avatar jdm avatar kaspth avatar kmcallister avatar mrb avatar nrc avatar pixeltrix avatar rafaelfranca avatar sgrif avatar sinistersnare 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.