feat(cli): serve the bundled skill with trx skills - #28
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Agents can now load the skill without installing it out of band: trx skills list trx skills get trx --full Adds skills to package.json files, so the directory actually ships to npm. It never did, which is why the bundled skill sat at 0.5.0 while the CLI shipped 0.6.1 with nobody noticing: nothing consumed it. Resolution order is TRX_SKILLS_DIR, then ../skills relative to this file, then a walk up for repo checkouts. Verified against a real global install from the packed tarball, the layout that broke skill resolution for another CLI on this machine. The shorthand router now derives its subcommand list from program.commands instead of a hardcoded array. It did not know about skills, so trx skills tried to transcribe the skills directory. Fixes #25 Fixes #26
The skill now tells an agent how to load the skill, which is the point of shipping it with the CLI.
Railly
force-pushed
the
feat/skills-command
branch
from
August 7, 2026 19:45
0a4fa1e to
90a707a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #25. Fixes #26.
What
trxnow serves its own agent manual, so an agent loads it with one command instead of installing it out of band:Why it matters here
skillswas never inpackage.jsonfiles, sopackages/cli/skills/never entered the npm tarball. Nobody consumed it from an install, and that is how the bundled skill sat at 0.5.0 while the CLI shipped 0.6.1 without anyone noticing.Prior art
Modeled on
agent-browser, which serves its skills the same way. There is no compile-time embedding involved: skill files are plain markdown that travel in the package and are read from disk at runtime, with resolution relative to the entry point and an env var as the escape hatch.Surface
trx skills listtrx skills get <name>trx skills get <name> --fullreferences/andtemplates/with--- path ---separatorstrx skills get --alltrx skills path [name]--output jsonworks on all of them and returns the same{success, data}envelope the other trx commands use.TRX_SKILLS_DIRoverrides resolution.Two bugs found by running it
Both were invisible until the command was executed, not read:
trx skillstried to transcribe the skills directory. The shorthand router matched against a hardcoded subcommand array that did not includeskills. It now derives the list fromprogram.commands, so adding a command no longer requires remembering to update a second place.descriptioncame back as"|". The frontmatter parser did not handle YAML block scalars, and this skill's description is one. Now parsed, with a regression test asserting it is not the block marker.Verification
The acceptance criterion from #26 was a clean global install, since path-relative skill resolution is exactly what broke
@native-sdk/clion this machine. Packed the real tarball and installed it into an isolated prefix:It works because bun links the bin as a symlink into the package and
import.meta.urlresolves to the real file, so../skillslands inside the installed package.--full, both error paths, path, block-scalar frontmatter, andTRX_SKILLS_DIR)bun run buildinpackages/websitesucceeds,0.7.0renders in the changelogNote on the skill content
This branch leaves
skills/trx/SKILL.mdat its current content on main. The version bump and the merge of the divergent copy are in #27, which should land first or be rebased.