Skip to content

Getting started

Runs on Claude Code and Codex CLI. trailhead is authored once; the installer projects host-native artifacts. On Claude Code: a skill + /trailhead:* commands + hooks. On Codex CLI: a native skill invoked $trailhead, one $trailhead-<verb> skill per verb for discoverability, and the guardrails as native Codex hooks. Choose the host with --claude / --codex, or let the installer auto-detect.

  • An authenticated gh CLI (the tracker is GitHub Issues).
  • A GitHub repo to work in.
  • For the npm path, Node 18+.

New to Git and GitHub? Start with the section below.

Already have a GitHub account and gh logged in? Skip to Install.

The three words you need

  • A repository (repo) is the project folder GitHub tracks. trailhead’s code lives in one.
  • An issue is a GitHub to-do item. Every trailhead map and ticket is an issue.
  • A commit is a saved snapshot of code changes. When trailhead works a ticket, it makes commits linked to that ticket.

From zero to a working setup

  1. Create a free GitHub account.

  2. Install Git and the GitHub CLI (gh).

  3. Run gh auth login and follow the prompts to sign in to GitHub.com. The browser login is the easiest, and letting it set up Git with your GitHub credentials means pushes just work. The prompts vary by version; the official manual is the authority.

  4. Check it worked:

    gh auth status

    It should report that you are logged in to github.com with your account.

  5. Create a private repo and enter it (manual; or use the web page instead):

    gh repo create my-project --private --clone
    cd my-project
  6. Start your agent in that folder and continue with Install, then After installing.

Step 5 is the explicit route, not the only one: /trailhead:new (Codex: $trailhead new) in a folder with no GitHub repo offers to create a private one for you.

Going deeper

Native install, managed by /plugin:

/plugin marketplace add ToRvaLDz/trailhead
/plugin install trailhead@trailhead

Update with /plugin update trailhead; remove with /plugin uninstall trailhead.

Re-run the install to update, or run /trailhead:update (Claude) / $trailhead update (Codex) from inside the agent: it detects how trailhead was installed and installs the newer version where that is safe. Release notes are in the CHANGELOG.

Restart or reload your agent so the commands register, then run /trailhead to start (smart entry), or /trailhead:new "<idea>" to chart a map. On Codex the surface is $trailhead instead: run $trailhead for smart entry, $trailhead new "<idea>" to chart, or a per-verb $trailhead-<verb> skill.

To let trailhead work a whole map while you are away, see Autonomous run.

Note: once installed, the commit guard hook runs on every git commit (enforcing Conventional Commits and blocking Co-Authored-By); disable the plugin’s hooks in settings if you don’t want that. Either way trailhead is self-contained: no external skill or plugin is required, no preflight, no version drift.

Next: read Core concepts for the map/ticket/frontier/fog vocabulary, or jump straight to Commands for the full verb list.