message

package
v0.8.4 Latest Latest
Warning

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

Go to latest
Published: May 30, 2018 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const Task_Failed = 0 // 执行失败
View Source
const Task_Status_Default = 0 // 任务未开始
View Source
const Task_Status_End = 2 // 任务完成
View Source
const Task_Status_Starting = 1 // 任务开始
View Source
const Task_Success = 1 // 执行成功

Variables

This section is empty.

Functions

This section is empty.

Types

type Task

type Task struct {
	TaskMessages []*TaskMessage
	// contains filtered or unexported fields
}

func NewTask

func NewTask() *Task

func (*Task) Add

func (t *Task) Add(taskLogId string, path string, gitX utils.GitXParams, preCommandX utils.CommandXParams, postCommandX utils.CommandXParams) error

add a task message

func (*Task) Delete

func (t *Task) Delete(taskLogId string) error

delete a task

func (*Task) End

func (t *Task) End(taskLogId string, isSuccess int, result string, commitId string) (err error)

task start

func (*Task) GetDefaultTasks

func (t *Task) GetDefaultTasks() []*TaskMessage

get a task

func (*Task) GetTask

func (t *Task) GetTask(taskLogId string) (*TaskMessage, error)

get a task

func (*Task) PathIsHaveTask

func (t *Task) PathIsHaveTask(path string) bool

path is have staring task

func (*Task) Start

func (t *Task) Start(taskLogId string) (err error)

task start

type TaskMessage

type TaskMessage struct {
	TaskLogId    string
	Path         string
	Status       int
	IsSuccess    int
	GitX         utils.GitXParams
	PreCommandX  utils.CommandXParams
	PostCommandX utils.CommandXParams
	Result       string
	CommitId     string
}

Jump to

Keyboard shortcuts

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