todo

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2023 License: MIT Imports: 5 Imported by: 12

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrUnexpectedCommand = errors.New("unexpected command")
	ErrMissingLabel      = errors.New("missing label")
	ErrMissingCommit     = errors.New("missing commit")
	ErrMissingExecCmd    = errors.New("missing command for exec")
	ErrMissingRef        = errors.New("missing ref")
)

Functions

func Write added in v0.0.4

func Write(f io.Writer, todos []Todo, commentChar byte) error

Types

type Todo

type Todo struct {
	Command     TodoCommand
	Commit      string
	Flag        string
	Comment     string
	ExecCommand string
	Label       string
	Msg         string
	Ref         string
}

func Parse

func Parse(f io.Reader, commentChar byte) ([]Todo, error)

type TodoCommand

type TodoCommand int
const (
	Pick TodoCommand = iota + 1
	Revert
	Edit
	Reword
	Fixup
	Squash

	Exec
	Break
	Label
	Reset
	Merge

	NoOp
	Drop
	UpdateRef

	Comment
)

func (TodoCommand) String

func (t TodoCommand) String() string

Jump to

Keyboard shortcuts

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