GithubHelp home page GithubHelp logo

amesianx / mattermost-plugin-github Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mattermost/mattermost-plugin-github

0.0 2.0 0.0 759 KB

GitHub plugin for Mattermost

License: Apache License 2.0

Makefile 7.03% Go 66.42% JavaScript 26.56%

mattermost-plugin-github's Introduction

Mattermost GitHub Plugin Build Status

A GitHub plugin for Mattermost. The plugin is currently in beta.

Features

  • Daily reminders - the first time you log in to Mattermost each day, get a post letting you know what issues and pull requests need your attention
  • Notifications - get a direct message in Mattermost when someone mentions you, requests your review, comments on or modifies one of your pull requests/issues, or assigns you on GitHub
  • Sidebar buttons - stay up-to-date with how many reviews, unread messages, assignments and open pull requests you have with buttons in the Mattermost sidebar
  • Slash commands - interact with the GitHub plugin using the /github slash command
    • Subscribe to a respository - Use /github subscribe to subscribe a Mattermost channel to receive posts for new pull requests and/or issues in a GitHub repository
    • Get to do items - Use /github todo to get an ephemeral message with items to do in GitHub
    • Update settings - Use /github settings to update your settings for the plugin
    • And more! - Run /github help to see what else the slash command can do
  • Supports GitHub Enterprise - Works with SaaS and Enterprise versions of GitHub (Enterprise support added in version 0.6.0)

Installation

Requires Mattermost 5.2 or higher. If you're running Mattermost 5.6+, it is strongly recommended to use plugin version 0.7.1+

If you're using GitHub Enterprise, replace all GitHub links below with your GitHub Enterprise URL

  1. Install the plugin
    1. Download the latest version of the plugin from the GitHub releases page
    2. In Mattermost, go the System Console -> Plugins -> Management
    3. Upload the plugin
  2. Register a GitHub OAuth app
    1. Go to https://github.com/settings/applications/new
    2. In Mattermost, go to System Console -> Plugins -> GitHub
      • Fill in the Client ID and Secret and save the settings
  3. Create a GitHub webhook
    1. In Mattermost, go to the System Console -> Plugins -> GitHub and copy the "Webhook Secret"
    2. Go to the settings page of your GitHub organization and click on "Webhooks" in the sidebar
      • Click "Add webhook"
      • Use "https://your-mattermost-url.com/plugins/github/webhook" as the payload URL, replacing https://your-mattermost-url.com with your Mattermost URL
      • Change content type to "application/json"
      • Paste the webhook secret you copied before into the secret field
      • Select the events: Issues, Issue comments, Pull requests, Pull request reviews, Pull request review comments, Pushes, Branch or Tag creation and Branch or Tag deletion
    3. Save the webhook
    4. Note for each organization you want to receive notifications for or subscribe to, you must create a webhook
  4. Configure a bot account
    1. Create a new Mattermost user, through the regular UI or the CLI with the username "github"
    2. Go to the System Console -> Plugins -> GitHub and select this user in the User setting
    3. Save the settings
  5. Generate an at rest encryption key
    1. Go to the System Console -> Plugins -> GitHub and click "Regenerate" under "At Rest Encryption Key"
    2. Save the settings
  6. (Optional) Lock the plugin to a GitHub organization
    • Go to System Console -> Plugins -> GitHub and set the GitHub Organization field to the name of your GitHub organization
  7. (Enterprise only) Set your Enterprise URLs
    • Go to System Console -> Plugins -> GitHub and set the Enterprise Base URL and Enterprise Upload URL fields to your GitHub Enterprise URLs, ex: https://github.example.com
    • The Base and Upload URLs are often the same
  8. Enable the plugin
    • Go to System Console -> Plugins -> Management and click "Enable" underneath the GitHub plugin
  9. Test it out
    • In Mattermost, run the slash command /github connect

Developing

This plugin contains both a server and web app portion.

Use make dist to build distributions of the plugin that you can upload to a Mattermost server.

Use make check-style to check the style.

Use make localdeploy to deploy the plugin to your local server. You will need to restart the server to get the changes.

Frequently Asked Questions

How do I connect a repository instead of an organization?

Set up your GitHub webhook from the repository instead of the organization. Notifications and subscriptions will then be sent only for repositories you create webhooks for.

The reminder and /github todo will still search the whole organization, but only list items assigned to you.

Feedback and Feature Requests

Feel free to create a GitHub issue or join the GitHub Plugin channel on our community Mattermost instance to discuss.

mattermost-plugin-github's People

Contributors

jwilander avatar crspeller avatar cpanato avatar hanzei avatar jasonblais avatar chvp avatar pushkyn avatar chetanyakan avatar lieut-data avatar

Watchers

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