gitlab-haskell-1.0.0.3: A Haskell library for the GitLab web API
Copyright(c) Rob Stewart Heriot-Watt University 2019
LicenseBSD3
Maintainerrobstewart57@gmail.com
Stabilitystable
Safe HaskellSafe-Inferred
LanguageHaskell2010

GitLab.API.MergeRequests

Description

 
Synopsis

List merge requests

mergeRequests Source #

Arguments

:: Project

the project

-> GitLab [MergeRequest] 

returns the merge requests for a project.

mergeRequestsWith Source #

Arguments

:: Project

the project

-> MergeProjectAttrs

merge request search attributes

-> GitLab [MergeRequest] 

returns the merge requests for a project and a set of search attributes as Just values in MergeProjectAttrs. The mrAttrs value has default merge request search values, which is a record that can be modified with Just values.

For example to search only for open merge requests for a project:

mergeRequestsWith myProject (mrAttrs {mr_attr_state = Just MROpened})

Get single MR

mergeRequest Source #

Arguments

:: Project

project

-> Int

merge request IID

-> GitLab (Either (Response ByteString) (Maybe MergeRequest)) 

returns the merge request for a project given its merge request IID.

Create MR

createMergeRequest Source #

Arguments

:: Project

project

-> Text

source branch

-> Text

target branch

-> Int

target project ID

-> Text

merge request title

-> Text

merge request description

-> GitLab (Either (Response ByteString) (Maybe MergeRequest)) 

Creates a merge request.

Accept MR

acceptMergeRequest Source #

Arguments

:: Project

project

-> Int

merge request IID

-> GitLab (Either (Response ByteString) (Maybe MergeRequest)) 

Accepts a merge request.

Delete a merge request

deleteMergeRequest Source #

Arguments

:: Project

project

-> Int

merge request IID

-> GitLab (Either (Response ByteString) (Maybe ())) 

Deletes a merge request. Only for admins and project owners.

merge request attributes

mrAttrs :: MergeProjectAttrs Source #

No merge request search filters, thereby returning all merge requests. Default scope is "all".

data MergeProjectAttrs Source #

Attributes when searching for merge requests with the mergeRequestsWith functions.

Constructors

MergeProjectAttrs 

Fields

data MergeRequestState Source #

for filtering by merge request state.

Constructors

MROpened

return only opened merge requests

MRClosed

return only closed merge requests

MRLocked

return only locked merge requests

MRMerged

return only merged merge requests

Instances

Instances details
Show MergeRequestState Source # 
Instance details

Defined in GitLab.API.MergeRequests

data WIP Source #

WIP status of merge requests

Constructors

WIPYes

return only draft merge requests

WIPNo

return non-draft merge requests

Instances

Instances details
Show WIP Source # 
Instance details

Defined in GitLab.API.MergeRequests

Methods

showsPrec :: Int -> WIP -> ShowS #

show :: WIP -> String #

showList :: [WIP] -> ShowS #