Documentation
¶
Overview ¶
Package signal writes and reads a pursuit's signal as markdown: its claim, its direction (what counts for and what counts against), the window it is read in and its resolver, every part checked present and every problem reported together on one line. It does no I/O and resolves nothing; callers hand it text and the day it is, and keep what it returns.
Index ¶
Constants ¶
const Layout = "2006-01-02"
Layout is how a window is written: a date, YYYY-MM-DD.
Variables ¶
This section is empty.
Functions ¶
func Check ¶
Check returns every problem with s on the day today falls on, in the order the parts are written: a part left empty, and a window that is not a date or is before today. None means s may be recorded.
Types ¶
type Signal ¶
type Signal struct {
Claim string // what should change, in the team's words
For string // what counts as for the claim
Against string // what counts as against it
Window string // the day it is read, YYYY-MM-DD
Resolver string // who or what reports the result: a named person or check
}
Signal is what a pursuit is read against. Every part is required.
func Parse ¶
Parse reads a signal from markdown and checks it on the day today falls on. Headings match without regard to case or surrounding space, comments are dropped and the title line is ignored. Under Direction, "For:" and "Against:" each start their part. Every problem found is returned together in one error.