feat(skills): add curated remote skill source backed by gitlab.com
Description
Follow-up to !3237 (merged) (which itself follows !3235 (merged)). Adds support for installing agent skills that live in public gitlab.com projects, via a curated registry maintained in this repo.
Architecture
Three new packages under internal/commands/skills/:
skill— shared types only (Skill { Name, Description, Source, Files }and aSourceenum).registry— aggregator over every source. Owns the user-facing "unknown skill" error and uses per-sourceErrNotFoundsentinels so genuine load/network failures propagate unmasked.remote— gitlab.com source.registry.yamlis the curated list, embedded via//go:embed.All()is fully offline (description comes from the YAML).Get(name)fetches the whole skill directory tree anonymously via the Repository APIs. Thelatestref is special-cased to the project's default branch; tags, SHAs, and other refs pass through unchanged.
install and list now consume the aggregator instead of bundled directly. list gains a Source column so users can tell where a skill comes from before installing.
Maintainer tooling
scripts/skills/add-remote takes a gitlab.com tree/blob URL, fetches the SKILL.md, parses its frontmatter, and writes a sorted registry entry. Catches the most common copy-paste mistakes (frontmatter name not matching the skill directory) and normalizes branch-like refs to latest.
First remote skill
orbit is registered with ref: latest so updates from the Orbit team don't need a registry MR. Multi-file install works end-to-end — Orbit ships SKILL.md plus a references/ directory, both round-trip.
Trust model
Curation in this repo's MR history is the trust model. Approving an MR that adds an entry vouches for the publishing project + ref. With ref: latest, our trust shifts to "this project's maintainers" rather than "this content" — same model as apt-get install. Per-entry tightening to a tag or SHA is available for any skill that warrants stricter pinning.
Why not the agentskills.io skills-ref validator
Its README states "This library is intended for demonstration purposes only. It is not meant to be used in production." Same reasoning as in !3237 (merged) — we keep validation minimal and let MR review handle full spec compliance.
Related
Depends on !3237 (merged). Retarget to main (or to whichever ancestor merges first) as the stack progresses.
How has this been tested?
bundled,registry,remote,install, andlistpackages all have unit tests covering the new shape.remote/remote_test.gomocks gitlab.com viahttptest(raw HTTP — fetcher doesn't use the client-go SDK sogitlabtestingdoesn't apply).- Manually verified end-to-end:
glab skills listshowsglab,glab-stack(bundled), andorbit(remote) with a Source column.glab skills install orbit --path /tmp/xfetches the liveSKILL.mdplus the entirereferences/directory.glab skills install(no arg) installs only bundled skills; remote is opt-in by name.glab skills install does-not-existreturns the registry's "unknown skill" error pointing toglab skills list.go run ./scripts/skills/add-remote https://gitlab.com/gitlab-org/orbit/knowledge-graph/-/tree/main/skills/orbitproduced the committed registry entry.
validate-skillslefthook hook now covers every package underinternal/commands/skills/, so a bad remote registry entry fails locally at commit time.
Screenshots (if appropriate):
N/A