gitsources: add commit status of type `error`
This commit is contained in:
parent
81d557d785
commit
2d6ddd0e74
|
@ -69,6 +69,8 @@ func fromCommitStatus(status gitsource.CommitStatus) gitea.StatusState {
|
||||||
return gitea.StatusPending
|
return gitea.StatusPending
|
||||||
case gitsource.CommitStatusSuccess:
|
case gitsource.CommitStatusSuccess:
|
||||||
return gitea.StatusSuccess
|
return gitea.StatusSuccess
|
||||||
|
case gitsource.CommitStatusError:
|
||||||
|
return gitea.StatusError
|
||||||
case gitsource.CommitStatusFailed:
|
case gitsource.CommitStatusFailed:
|
||||||
return gitea.StatusFailure
|
return gitea.StatusFailure
|
||||||
default:
|
default:
|
||||||
|
|
|
@ -63,6 +63,8 @@ func fromCommitStatus(status gitsource.CommitStatus) gitlab.BuildStateValue {
|
||||||
return gitlab.Pending
|
return gitlab.Pending
|
||||||
case gitsource.CommitStatusSuccess:
|
case gitsource.CommitStatusSuccess:
|
||||||
return gitlab.Success
|
return gitlab.Success
|
||||||
|
case gitsource.CommitStatusError:
|
||||||
|
return gitlab.Failed
|
||||||
case gitsource.CommitStatusFailed:
|
case gitsource.CommitStatusFailed:
|
||||||
return gitlab.Failed
|
return gitlab.Failed
|
||||||
default:
|
default:
|
||||||
|
|
|
@ -27,6 +27,7 @@ type CommitStatus string
|
||||||
const (
|
const (
|
||||||
CommitStatusPending CommitStatus = "pending"
|
CommitStatusPending CommitStatus = "pending"
|
||||||
CommitStatusSuccess CommitStatus = "success"
|
CommitStatusSuccess CommitStatus = "success"
|
||||||
|
CommitStatusError CommitStatus = "error"
|
||||||
CommitStatusFailed CommitStatus = "failed"
|
CommitStatusFailed CommitStatus = "failed"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue