hooks

package
v0.0.0-...-d2f2feb Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2019 License: MIT Imports: 10 Imported by: 1

Documentation

Overview

Package hooks hold actions on the Bitbucket hooks

Package hooks hold actions on the Bitbucket hooks

Package hooks hold actions on the Bitbucket hooks

Package hooks hold actions on the Bitbucket hooks

Package hooks hold actions on the Bitbucket hooks

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SpaceStringsBuilder

func SpaceStringsBuilder(str string) string

SpaceStringsBuilder Strips whitespace from a string

Types

type Command

type Command struct {
	Settings *settings.BitAdminSettings
}

Command define base struct for repository subcommands and actions

func (*Command) GetCommand

func (command *Command) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

type DiffReporter

type DiffReporter struct {
	// contains filtered or unexported fields
}

DiffReporter is a simple custom reporter that only records differences detected during comparison.

func (*DiffReporter) PopStep

func (r *DiffReporter) PopStep()

func (*DiffReporter) PushStep

func (r *DiffReporter) PushStep(ps cmp.PathStep)

func (*DiffReporter) Report

func (r *DiffReporter) Report(rs cmp.Result)

func (*DiffReporter) String

func (r *DiffReporter) String() string

type EolHookCommand

type EolHookCommand struct {
	Settings *settings.BitAdminSettings
}

EolHookCommand define the command for the Stash Check EOL hook

func (*EolHookCommand) GetCommand

func (command *EolHookCommand) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

type EolHookDisableCommand

type EolHookDisableCommand struct {
	Settings *settings.BitAdminSettings
	// contains filtered or unexported fields
}

EolHookDisableCommand define the command to disable the YACC hook

func (*EolHookDisableCommand) DisableAction

func (command *EolHookDisableCommand) DisableAction(context *cli.Context) error

DisableAction contains logic to turn on the hook and set its configuration

func (*EolHookDisableCommand) GetCommand

func (command *EolHookDisableCommand) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

type EolHookDisableCommandFlags

type EolHookDisableCommandFlags struct {
	// contains filtered or unexported fields
}

EolHookDisableCommandFlags define the flags of the EolHookDisableCommand

type EolHookEnableCommand

type EolHookEnableCommand struct {
	Settings *settings.BitAdminSettings
	// contains filtered or unexported fields
}

EolHookEnableCommand define the command to enable the EOL hook

func (*EolHookEnableCommand) EnableAction

func (command *EolHookEnableCommand) EnableAction(context *cli.Context) error

EnableAction contains logic to turn on the hook and set its configuration

func (*EolHookEnableCommand) GetCommand

func (command *EolHookEnableCommand) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

type EolHookEnableCommandFlags

type EolHookEnableCommandFlags struct {
	// contains filtered or unexported fields
}

EolHookEnableCommandFlags define the flags for the EolHookEnableCommand

type EolSettings

type EolSettings struct {
	ExcludeFiles      string `json:"excludeFiles,omitempty"`
	AllowInheritedEol bool   `json:"allowInheritedEol,omitempty"`
}

EolSettings define the settings of the EOL hook

type ListHooksCommand

type ListHooksCommand struct {
	Settings *settings.BitAdminSettings
	// contains filtered or unexported fields
}

ListHooksCommand define command to retrieve hooks on a given repository

func (*ListHooksCommand) GetCommand

func (command *ListHooksCommand) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

func (*ListHooksCommand) ListHooksAction

func (command *ListHooksCommand) ListHooksAction(context *cli.Context) error

ListHooksAction contains logic to list hooks on given repository

type ListHooksCommandFlags

type ListHooksCommandFlags struct {
	// contains filtered or unexported fields
}

ListHooksCommandFlags define the flags for the ListHooksCommand

type PubHookCommand

type PubHookCommand struct {
	Settings *settings.BitAdminSettings
}

PubHookCommand define the command for the Protect Unmerged Branch hook

func (*PubHookCommand) GetCommand

func (command *PubHookCommand) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

type PubHookDisableCommand

type PubHookDisableCommand struct {
	Settings *settings.BitAdminSettings
	// contains filtered or unexported fields
}

PubHookDisableCommand define the command to disable the YACC hook

func (*PubHookDisableCommand) DisableAction

func (command *PubHookDisableCommand) DisableAction(context *cli.Context) error

DisableAction contains logic to turn on the hook and set its configuration

func (*PubHookDisableCommand) GetCommand

func (command *PubHookDisableCommand) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

type PubHookDisableCommandFlags

type PubHookDisableCommandFlags struct {
	// contains filtered or unexported fields
}

PubHookDisableCommandFlags define the flags of the PubHookDisableCommand

type PubHookEnableCommand

type PubHookEnableCommand struct {
	Settings *settings.BitAdminSettings
	// contains filtered or unexported fields
}

PubHookEnableCommand define the command to enable the PUB hook

func (*PubHookEnableCommand) EnableAction

func (command *PubHookEnableCommand) EnableAction(context *cli.Context) error

EnableAction contains logic to turn on the hook and set its configuration

func (*PubHookEnableCommand) GetCommand

func (command *PubHookEnableCommand) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

type PubHookEnableCommandFlags

type PubHookEnableCommandFlags struct {
	// contains filtered or unexported fields
}

PubHookEnableCommandFlags define the flags for the PubHookEnableCommand

type RfpHookCommand

type RfpHookCommand struct {
	Settings *settings.BitAdminSettings
}

RfpHookCommand define the command for the Reject Force Push hook

func (*RfpHookCommand) GetCommand

func (command *RfpHookCommand) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

type RfpHookDisableCommand

type RfpHookDisableCommand struct {
	Settings *settings.BitAdminSettings
	// contains filtered or unexported fields
}

RfpHookDisableCommand define the command to disable the YACC hook

func (*RfpHookDisableCommand) DisableAction

func (command *RfpHookDisableCommand) DisableAction(context *cli.Context) error

DisableAction contains logic to turn on the hook and set its configuration

func (*RfpHookDisableCommand) GetCommand

func (command *RfpHookDisableCommand) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

type RfpHookDisableCommandFlags

type RfpHookDisableCommandFlags struct {
	// contains filtered or unexported fields
}

RfpHookDisableCommandFlags define the flags of the RfpHookDisableCommand

type RfpHookEnableCommand

type RfpHookEnableCommand struct {
	Settings *settings.BitAdminSettings
	// contains filtered or unexported fields
}

RfpHookEnableCommand define the command to enable the PUB hook

func (*RfpHookEnableCommand) EnableAction

func (command *RfpHookEnableCommand) EnableAction(context *cli.Context) error

EnableAction contains logic to turn on the hook and set its configuration

func (*RfpHookEnableCommand) GetCommand

func (command *RfpHookEnableCommand) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

type RfpHookEnableCommandFlags

type RfpHookEnableCommandFlags struct {
	// contains filtered or unexported fields
}

RfpHookEnableCommandFlags define the flags for the RfpHookEnableCommand

type YaccHookCommand

type YaccHookCommand struct {
	Settings *settings.BitAdminSettings
}

YaccHookCommand define the command for the Yet Another Commit Checker hook

func (*YaccHookCommand) GetCommand

func (command *YaccHookCommand) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

type YaccHookDiffSettingsCommand

type YaccHookDiffSettingsCommand struct {
	Settings *settings.BitAdminSettings
	// contains filtered or unexported fields
}

YaccHookSettingsCommand define the command to get setting for YACC hook

func (*YaccHookDiffSettingsCommand) DiffSettings

func (command *YaccHookDiffSettingsCommand) DiffSettings(context *cli.Context) error

DiffSettings contains logic to get diff between defined default settings and current setting got for specific repository

func (*YaccHookDiffSettingsCommand) GetCommand

func (command *YaccHookDiffSettingsCommand) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

type YaccHookDiffSettingsCommandFlags

type YaccHookDiffSettingsCommandFlags struct {
	// contains filtered or unexported fields
}

YaccHookGetSettingsCommandFlags define the flags of the YaccHookSettingsCommand

type YaccHookDisableCommand

type YaccHookDisableCommand struct {
	Settings *settings.BitAdminSettings
	// contains filtered or unexported fields
}

YaccHookDisableCommand define the command to disable the YACC hook

func (*YaccHookDisableCommand) DisableAction

func (command *YaccHookDisableCommand) DisableAction(context *cli.Context) error

DisableAction contains logic to turn on the hook and set its configuration

func (*YaccHookDisableCommand) GetCommand

func (command *YaccHookDisableCommand) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

type YaccHookDisableCommandFlags

type YaccHookDisableCommandFlags struct {
	// contains filtered or unexported fields
}

YaccHookDisableCommandFlags define the flags of the YaccHookDisableCommand

type YaccHookEnableCommand

type YaccHookEnableCommand struct {
	Settings *settings.BitAdminSettings
	// contains filtered or unexported fields
}

YaccHookEnableCommand define the command to enable the YACC hook

func (*YaccHookEnableCommand) EnableAction

func (command *YaccHookEnableCommand) EnableAction(context *cli.Context) error

EnableAction contains logic to turn on the hook and set its configuration

func (*YaccHookEnableCommand) GetCommand

func (command *YaccHookEnableCommand) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

type YaccHookEnableCommandFlags

type YaccHookEnableCommandFlags struct {
	// contains filtered or unexported fields
}

YaccHookEnableCommandFlags define the flags for the YaccHookEnableCommand

type YaccHookGetSettingsCommandFlags

type YaccHookGetSettingsCommandFlags struct {
	// contains filtered or unexported fields
}

YaccHookGetSettingsCommandFlags define the flags of the YaccHookSettingsCommand

type YaccHookSettingsCommand

type YaccHookSettingsCommand struct {
	Settings *settings.BitAdminSettings
	// contains filtered or unexported fields
}

YaccHookSettingsCommand define the command to get setting for YACC hook

func (*YaccHookSettingsCommand) GetCommand

func (command *YaccHookSettingsCommand) GetCommand() cli.Command

GetCommand provide a ready to use cli.Command

func (*YaccHookSettingsCommand) GetSettings

func (command *YaccHookSettingsCommand) GetSettings(context *cli.Context) error

GetSettings contains logic to get current yacc settings

type YaccSettings

type YaccSettings struct {
	RequireMatchingAuthorEmail     bool   `json:"requireMatchingAuthorEmail,omitempty"`
	RequireMatchingAuthorName      bool   `json:"requireMatchingAuthorName,omitempty"`
	CommitterEmailRegex            string `json:"committerEmailRegex,omitempty"`
	CommitMessageRegex             string `json:"commitMessageRegex,omitempty"`
	RequireJiraIssue               bool   `json:"requireJiraIssue,omitempty"`
	IgnoreUnknownIssueProjectKeys  bool   `json:"ignoreUnknownIssueProjectKeys,omitempty"`
	IssueJqlMatcher                string `json:"issueJqlMatcher,omitempty"`
	BranchNameRegex                string `json:"branchNameRegex,omitempty"`
	ErrorMessageHeader             string `json:"errorMessageHeader,omitempty"`
	ErrorMessageCommiterEmail      string `json:"errorMessage.COMMITER_EMAIL,omitempty"`
	ErrorMessageCommiterEmailRegex string `json:"errorMessage.COMMITER_EMAIL_REGEX,omitempty"`
	ErrorMessageCommiterName       string `json:"errorMessage.COMMITER_NAME,omitempty"`
	ErrorMessageCommitRegex        string `json:"errorMessage.COMMIT_REGEX,omitempty"`
	ErrorMessageIssueJQL           string `json:"errorMessage.ISSUE_JQL,omitempty"`
	ErrorMessageBranchName         string `json:"errorMessage.BRANCH_NAME,omitempty"`
	ErrorMessageFooter             string `json:"errorMessageFooter,omitempty"`
	ExcludeMergeCommits            bool   `json:"excludeMergeCommits,omitempty"`
	ExcludeByRegex                 string `json:"excludeByRegex,omitempty"`
	ExcludeBranchRegex             string `json:"excludeBranchRegex,omitempty"`
	ExcludeServiceUserCommits      bool   `json:"excludeServiceUserCommits,omitempty"`
	ExcludeUsers                   string `json:"excludeUsers,omitempty"`
}

YaccSettings define the settings of the YACC hook

Jump to

Keyboard shortcuts

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