@romainseb/pr-man
TypeScript icon, indicating that this package has built-in type declarations

0.0.8 • Public • Published

PR MAN

This module allow you by setting a little configuration to send on slack some pull request status for your team

How it works

This module is run by calling the exported runPrMan function

import { runPrMan } from "@romainseb/pr-man"
import configurations from "./configurations"

const githubToken = process.env.GITHUB_TOKEN_API
const slackToken = process.env.SLACK_TOKEN_API

runPrMan(configurations, githubToken, slackToken)

How to setup your configuration

The first parameter of runPrMan is a configuration or a list of configurations ( in order to work on multiple teams in one execution )

A configuration is composed by:

  • slackChannel : The channel when you want the message to be send ( your slack token should have access to this channel )
  • title (optional) : If you want to have a title before the listing of your pull request
  • users : a list of users with this format
  • repositories : a list of github repositories

user example

import { Role } from "@romainseb/pr-man"

const users = [
	{
		githubUserName: "romainseb",
		slackUserName: "sromain",
		role: Role.FRONTEND
	}
]

repository example

import { Role } from "@romainseb/pr-man"

const repositories = [
	{
		owner: "talend",
		repository: "ui",
		ignoreLabels: ["work in progress"],
		reviewRequired: 2,
		label: "UI"
	}
]

Readme

Keywords

none

Package Sidebar

Install

npm i @romainseb/pr-man

Weekly Downloads

1

Version

0.0.8

License

MIT

Unpacked Size

123 kB

Total Files

22

Last publish

Collaborators

  • romainseb