Documentation
¶
Index ¶
- func DisplayAllMRs(streams *iostreams.IOStreams, mrs []*gitlab.MergeRequest) string
- func DisplayMR(c *iostreams.ColorPalette, mr *gitlab.MergeRequest, isTTY bool) string
- func MRCheckErrors(mr *gitlab.MergeRequest, err MRCheckErrOptions) error
- func MRFromArgs(f *cmdutils.Factory, args []string, state string) (*gitlab.MergeRequest, glrepo.Interface, error)
- func MRFromArgsWithOpts(f *cmdutils.Factory, args []string, opts *gitlab.GetMergeRequestsOptions, ...) (*gitlab.MergeRequest, glrepo.Interface, error)
- func MRState(c *iostreams.ColorPalette, m *gitlab.MergeRequest) string
- func MRsFromArgs(f *cmdutils.Factory, args []string, state string) ([]*gitlab.MergeRequest, glrepo.Interface, error)
- func PrintMRApprovalState(ios *iostreams.IOStreams, mrApprovals *gitlab.MergeRequestApprovalState)
- func RebaseMR(ios *iostreams.IOStreams, apiClient *gitlab.Client, repo glrepo.Interface, ...) error
- type MRCheckErrOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DisplayAllMRs ¶
func DisplayMR ¶
func DisplayMR(c *iostreams.ColorPalette, mr *gitlab.MergeRequest, isTTY bool) string
func MRCheckErrors ¶
func MRCheckErrors(mr *gitlab.MergeRequest, err MRCheckErrOptions) error
MRCheckErrors checks and return merge request errors specified in MRCheckErrOptions{}
func MRFromArgs ¶
func MRFromArgs(f *cmdutils.Factory, args []string, state string) (*gitlab.MergeRequest, glrepo.Interface, error)
MRFromArgs is wrapper around MRFromArgsWithOpts without any custom options
func MRFromArgsWithOpts ¶
func MRFromArgsWithOpts( f *cmdutils.Factory, args []string, opts *gitlab.GetMergeRequestsOptions, state string, ) (*gitlab.MergeRequest, glrepo.Interface, error)
MRFromArgsWithOpts gets MR with custom request options passed down to it
func MRState ¶
func MRState(c *iostreams.ColorPalette, m *gitlab.MergeRequest) string
func MRsFromArgs ¶
func PrintMRApprovalState ¶
PrintMRApprovalState renders an output to summarize the approval state of a merge request
Types ¶
type MRCheckErrOptions ¶
type MRCheckErrOptions struct {
// WorkInProgress: check and return err if merge request is a DRAFT
WorkInProgress bool
// Closed : check and return err if merge request is closed
Closed bool
// Merged : check and return err if merge request is already merged
Merged bool
// Opened : check and return err if merge request is already opened
Opened bool
// Conflict : check and return err if there are merge conflicts
Conflict bool
// PipelineStatus : check and return err pipeline did not succeed and it is required before merging
PipelineStatus bool
// MergePermitted : check and return err if user is not authorized to merge
MergePermitted bool
// Subscribed : check and return err if user is already subscribed to MR
Subscribed bool
// Unsubscribed : check and return err if user is already unsubscribed to MR
Unsubscribed bool
// MergePrivilege : check and return err if user is not authorized to merge
MergePrivilege bool
}
Click to show internal directories.
Click to hide internal directories.