configs

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 23, 2022 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Token         string     `mapstructure:"token"`
	WebhookURL    string     `mapstructure:"webhook-url"`
	ReviewersList []Reviewer `mapstructure:"reviewers"`
}

func NewConfig

func NewConfig(token string, webhookURL string, reviewersList []Reviewer) Config

func (Config) GithubLoginBySlack

func (c Config) GithubLoginBySlack(slackLogin string) (string, error)

func (Config) GithubToken

func (c Config) GithubToken() string

func (Config) Reviewers

func (c Config) Reviewers() []Reviewer

func (Config) SlackLoginByGithub

func (c Config) SlackLoginByGithub(githubLogin string) (string, error)

func (Config) SlackWebhookUrl

func (c Config) SlackWebhookUrl() string

func (Config) ValidateConfig

func (c Config) ValidateConfig() error

type Reviewer

type Reviewer struct {
	GhLogin string `mapstructure:"github"`
	SlLogin string `mapstructure:"slack"`
}

func (Reviewer) GithubLogin

func (r Reviewer) GithubLogin() string

func (Reviewer) SlackLogin

func (r Reviewer) SlackLogin() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL