Documentation
¶
Overview ¶
Package market lists and fetches the lanes published in the jaira repository's own lanes/ directory on GitHub — the catalogue anyone can add to with a pull request, checked by CI before it lands.
The directory is the marketplace. There is no registry, no index file and no format of its own: what GitHub's contents API says is in lanes/ is what is on offer, and a lane arrives here the same way a teammate's shared lane does — parsed first, then adopted into the catalogue on purpose.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Overridden ¶
func Overridden() string
Overridden reports the override in effect, so a command can name it before installing a prompt that host served.
func Unpinned ¶ added in v0.3.1
func Unpinned() string
Unpinned reports that this build fetches the catalogue unpinned, empty when it is pinned to its own tag. The text is returned rather than printed, like Overridden above it: apiBase is a pure function called on every request, and a line written from inside it would appear once per call and land in the middle of --json output.
Types ¶
type Client ¶
Client talks to the catalogue host.
func New ¶
func New() *Client
New returns a Client with an explicit timeout — the zero-value http.Client has none, and a hung TLS handshake would hang the command forever.
func (*Client) Fetch ¶
Fetch downloads one listed lane's file, as served — what an adoption parses and copies. List has read the file once to describe it; fetching it again here costs one request and keeps the listing free of payloads that only one caller ever wanted.
func (*Client) List ¶
List fetches the catalogue: every *.md in the directory except its README, each downloaded and parsed so the listing can show id, name and description rather than filenames. A file that does not parse is a warning, not a failure — one broken contribution must not hide the rest.
type Entry ¶
type Entry struct {
Lane *lane.Lane
Path string // path inside the repository, e.g. lanes/critique.md
URL string // where the raw file is fetched from
}
Entry is one lane on offer: the parsed lane, and where its file lives. List shows; Fetch fetches — an Entry carries what the listing needs and nothing that only an adoption needs.