Documentation
¶
Overview ¶
Package infrastructure holds the routing adapters: the YAML loader for the mappings section of config.yaml, the config.lock read/write/diff/merge store, and the GitHub changed-files reader. It is the only routing layer that touches the filesystem or an external SDK; per the transition-debt rule it may import internal/github (and, transitionally, internal/store) until those move under platform/.
Index ¶
Constants ¶
const LockFileComment = "DO NOT EDIT — regenerated by notifycat on validation"
LockFileComment is the human-facing warning baked into every written lock.
const LockVersion = 1
LockVersion is the current lock-file schema version.
Variables ¶
This section is empty.
Functions ¶
func Load ¶
func Load(path string) (*application.Provider, error)
Load reads and validates the file at path.
func LockPath ¶
LockPath derives the lock-file path that lives next to the given mappings.yaml. .yaml / .yml extensions are swapped for .lock; any other suffix gets .lock appended.
Types ¶
type Diff ¶
Diff is the result of DiffEntries: entries needing validation + lock keys that should be dropped on the next write.
type FileNotFoundError ¶
FileNotFoundError is returned by Load when the mappings file cannot be opened.
func (*FileNotFoundError) Error ¶
func (e *FileNotFoundError) Error() string
func (*FileNotFoundError) Unwrap ¶
func (e *FileNotFoundError) Unwrap() error
type Lock ¶
type Lock struct {
Comment string `json:"_comment,omitempty"`
Version int `json:"version"`
Entries map[string]LockEntry `json:"entries"`
}
Lock is the on-disk validation cache.
type ParseError ¶
ParseError is returned by Load when the mappings file cannot be parsed.
func (*ParseError) Error ¶
func (e *ParseError) Error() string
func (*ParseError) Unwrap ¶
func (e *ParseError) Unwrap() error