Documentation
¶
Overview ¶
Package dates parses the human date and time forms the CLI accepts.
Every entry point takes an explicit "now" so callers are testable without mocking the clock.
Index ¶
Constants ¶
View Source
const NoneLiteral = "none"
NoneLiteral clears a nullable field. The API marks date, horizon, color and the foreign keys nullable, but there was previously no way to clear one from a flag: --date "" sends an empty string and is rejected.
Variables ¶
This section is empty.
Functions ¶
func Accepted ¶
func Accepted() string
Accepted describes the grammar, for help text and error messages.
func ParseClock ¶
ParseClock normalises a time of day to the "HH:MM" the API expects for start_time and end_time, which are format:time, not datetimes.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.