mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2026-03-16 17:54:07 +01:00
Let pipeline-compiler export step types (#1958)
This commit is contained in:
@@ -47,6 +47,7 @@ type Step struct {
|
||||
ExitCode int `json:"exit_code" xorm:"step_exit_code"`
|
||||
Started int64 `json:"start_time,omitempty" xorm:"step_started"`
|
||||
Stopped int64 `json:"end_time,omitempty" xorm:"step_stopped"`
|
||||
Type StepType `json:"type,omitempty" xorm:"step_type"`
|
||||
} // @name Step
|
||||
|
||||
type UpdateStepStore interface {
|
||||
@@ -67,3 +68,14 @@ func (p *Step) Running() bool {
|
||||
func (p *Step) Failing() bool {
|
||||
return p.Failure == FailureFail && (p.State == StatusError || p.State == StatusKilled || p.State == StatusFailure)
|
||||
}
|
||||
|
||||
// StepType identifies the type of step
|
||||
type StepType string // @name StepType
|
||||
|
||||
const (
|
||||
StepTypeClone StepType = "clone"
|
||||
StepTypeService StepType = "service"
|
||||
StepTypePlugin StepType = "plugin"
|
||||
StepTypeCommands StepType = "commands"
|
||||
StepTypeCache StepType = "cache"
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user