Documentation
¶
Overview ¶
Package registry fetches and parses the CheatMD cheat-pack registry: a remote YAML manifest that lists installable cheat repositories ("packs").
The registry is hosted in its own repo (see the cheatmd.registry scaffold); the tool fetches it over HTTPS during first-run setup so users can pick official packs of cheats to install.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Pack ¶
type Pack struct {
// Name is a short identifier, also used as the install subdirectory name.
Name string `yaml:"name"`
// Repo is the clonable repository URL (e.g. https://github.com/owner/repo).
Repo string `yaml:"repo"`
// Description is a one-line human summary shown in the picker.
Description string `yaml:"description"`
// Official marks packs as officially maintained, pre-selected during first-run.
Official bool `yaml:"official"`
// Subdir optionally restricts installation to .md files under this path
// within the repo. Empty means the whole repo.
Subdir string `yaml:"subdir"`
}
Pack describes a single installable cheat repository in the registry.
type Registry ¶
Registry is the parsed manifest.
func Parse ¶
Parse unmarshals registry YAML and validates required fields. It is split from Fetch so it can be unit-tested without a network round-trip.
func (*Registry) OfficialPacks ¶
OfficialPacks returns the packs flagged as official packs.