plan

package
v0.3.14 Latest Latest
Warning

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

Go to latest
Published: Mar 9, 2026 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Plan

type Plan struct {
	Title string `json:"title,omitempty"`
	Tasks []Task `json:"tasks"`
}

func (*Plan) Clear added in v0.3.6

func (p *Plan) Clear()

Clear resets the plan

func (*Plan) IsEmpty added in v0.3.6

func (p *Plan) IsEmpty() bool

IsEmpty returns true if no plan has been set

func (*Plan) SetTasks added in v0.3.6

func (p *Plan) SetTasks(title string, descriptions []string)

SetTasks creates a new plan with the given title and task descriptions

func (*Plan) UpdateTask added in v0.3.6

func (p *Plan) UpdateTask(index int, status Status) error

UpdateTask updates a task status by index

type Status

type Status string
const (
	StatusPending Status = "pending"
	StatusRunning Status = "running"
	StatusDone    Status = "done"
	StatusSkipped Status = "skipped"
)

type Task added in v0.3.6

type Task struct {
	Description string `json:"description"`
	Status      Status `json:"status"`
}

Jump to

Keyboard shortcuts

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