Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,18 @@ All notable changes to Trail are documented in this file. Trail follows

### Added

- `trail install <agent>` now installs an idempotent, provider-neutral suite of
five focused skills at user scope for Codex, Claude Code, GitHub Copilot,
Gemini CLI, Cursor, Windsurf, Cline, Roo Code, Kilo Code, OpenCode, Amp, Kiro
CLI, and Qwen Code. `trail-lanes`
covers concurrent work and shared immutable environments; `trail-workspace`
covers recording and provenance; `trail-agent-tasks` covers managed agent
review and Git handoff; `trail-integrations` covers CLI/MCP/ACP/hooks/HTTP;
and `trail-recovery` covers diagnosis and safe recovery. Independent triggers
keep unrelated capabilities out of ordinary agent context. The installer
inspects the complete suite for local edits, supports per-skill dry-run JSON
reports, and requires `--force` before replacing drifted or unmanaged content.

- Environment support now includes contained Go multi-module workspaces, real frozen
Yarn Classic and Bun handoffs, project-aware `uv sync --frozen`, and modern
CMake/Ninja/preset/toolchain/ccache/vcpkg planning. Node native addons and lifecycle
Expand All @@ -34,6 +46,13 @@ All notable changes to Trail are documented in this file. Trail follows

### Fixed

- Trail now pins `prolly-map` 0.6 and `prolly-store-sqlite` 0.4 together, so
the SQLite backend and Trail use the same `Store` trait and locked builds do
not resolve incompatible Prolly major-minor lines. This hardens schema v1 to
the 0.4 node layout with an explicit encoding column; workspaces created with
the earlier layout must be backed up and recreated with
`trail init --force --from-git`.

- Managed lane commands now derive fixed policy, resolved executable, cache,
and output bindings from each active environment adapter instead of injecting
Cargo/npm defaults globally. Go, pnpm/npm/Yarn/Bun, Python, and CMake commands
Expand Down
58 changes: 54 additions & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

23 changes: 23 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -535,6 +535,29 @@ Interactive Trail commands check for a newer stable release at most once every
disable those background checks. JSON, NDJSON, quiet, CI, and non-terminal
commands never emit update notices.

Install Trail's focused skill suite for the coding agent you use:

```sh
trail install codex
trail install claude
trail install cursor
trail install copilot
trail install gemini
```

The supported targets are `codex`, `claude`, `copilot`, `gemini`, `cursor`,
`windsurf`, `cline`, `roo`, `kilo`, `opencode`, `amp`, `kiro`, and `qwen`.
Trail installs the same portable Agent Skills payload into each agent's native
user-level discovery directory.

The command installs five independently triggered skills at user scope:
`trail-lanes`, `trail-workspace`, `trail-agent-tasks`, `trail-integrations`, and
`trail-recovery`. Together they cover concurrent lane work, ordinary recording
and provenance, managed coding-agent tasks, MCP/ACP/hooks/HTTP integration, and
safe diagnosis and recovery. Restart the agent after installation. Each skill
stays narrow so an ordinary lane task does not load integration or maintenance
instructions.

The Windows binary currently links the Dokany 2.0.6 runtime. Linux FUSE,
macFUSE, and the Dokan driver are otherwise relevant only to their
corresponding mounted-workspace modes.
Expand Down
1 change: 1 addition & 0 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ These docs are written from the current Rust code, CLI definitions, exported mod
- [Roadmap](../ROADMAP.md)
- [Changelog](../CHANGELOG.md)
- [Install and build](getting-started/install-and-build.md)
- [Install agent skills](reference/cli/integrations-and-maintenance.md#install-agent-skills)
- [Initialize a workspace](getting-started/initialize-a-workspace.md)
- [First record and provenance query](getting-started/first-record-and-query.md)
- [First lane workflow](getting-started/first-lane-workflow.md)
Expand Down
4 changes: 3 additions & 1 deletion docs/concepts/storage-indexes-and-backups.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,9 @@ The Trail index lives under:
The `prolly` crate is re-exported from the `trail` crate and is used for map roots and content-addressed tree structures.

Prolly tree nodes are stored in SQLite alongside Trail metadata for refs,
operations, derived indexes, and workspace bookkeeping.
operations, derived indexes, and workspace bookkeeping. The schema records the
node encoding used by `prolly-store-sqlite` 0.4, allowing raw and compressed
nodes to coexist without changing their content identities.

## Derived Indexes

Expand Down
5 changes: 5 additions & 0 deletions docs/design/storage-and-indexing.md
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,11 @@ Trail uses prolly maps for:

The design gives efficient range scans and diffs over sorted keys. Low-level inspection is exposed by `trail map range` and `trail map diff`, with map decoders for raw, path, file-index, text-order, and line-index map types.

Schema v1 follows `prolly-store-sqlite` 0.4's node layout. Each stored node
includes an explicit encoding discriminator so the backend can distinguish raw
and compressed node bytes. Trail validates that column and the backend's exact
table shape before opening an existing workspace.

## Worktree File Index

`worktree_file_index` caches file metadata and hashes:
Expand Down
46 changes: 46 additions & 0 deletions docs/getting-started/install-and-build.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,52 @@ trail --help
trail lane --help
```

## Install the Agent Skill Suite

After installing the Trail binary, install its focused skills for the coding
agent you use:

```sh
trail install codex
trail install claude
trail install cursor
trail install copilot
trail install gemini
```

Supported targets are `codex`, `claude`, `copilot`, `gemini`, `cursor`,
`windsurf`, `cline`, `roo`, `kilo`, `opencode`, `amp`, `kiro`, and `qwen`.
Aliases include `claude-code`, `github-copilot`, `gemini-cli`, `roo-code`,
`kilo-code`, `kiro-cli`, and `qwen-code`. See the
[integration reference](../reference/cli/integrations-and-maintenance.md#install-agent-skills)
for the exact user-level destination of every target. Restart the agent if it
does not detect the new top-level skills directory in the current session.

Re-running the command is idempotent and updates a Trail-owned installation.
Trail refuses to overwrite local edits or an unmanaged directory unless
`--force` is explicit. Preview the action without writing files with:

```sh
trail install codex --dry-run
trail install cursor --dry-run
```

The suite contains five independently triggered skills:

- `trail-lanes`: concurrent task isolation, reusable immutable environments,
private writable state, claims, gates, readiness, and merge preparation.
- `trail-workspace`: recording, selective paths, history, provenance, Trail
branches, checkout previews, and explicit Git handoff.
- `trail-agent-tasks`: high-level launch, review, validation, handoff, recovery,
readiness, and apply workflows for managed coding-agent tasks.
- `trail-integrations`: structured CLI, MCP, ACP relay, native hooks, and the
authenticated local HTTP daemon.
- `trail-recovery`: blockers, conflicts, rewind, doctor/fsck, backup, and safe
recovery without bypassing guardrails.

The split keeps unrelated capability instructions out of ordinary agent
context while making the useful Trail workflows discoverable when needed.

If `$HOME/.cargo/bin` is not on your `PATH`, either add it or call the binary
directly from that directory. For a project-local install, override `PREFIX`:

Expand Down
55 changes: 55 additions & 0 deletions docs/reference/cli/integrations-and-maintenance.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,61 @@ For day-to-day code-agent work, start with the `agent` commands. They create
fresh task lanes, keep agent work isolated, record checkpoints, and guide review
and apply.

## Install Agent Skills

```text
trail install <agent> [--dry-run] [--force]
```

This workspace-independent command installs Trail's provider-neutral skill
suite at user scope:

| Agent argument | Native user-level destination |
| --- | --- |
| `codex` | `$CODEX_HOME/skills/<skill>` or `~/.codex/skills/<skill>` |
| `claude` | `~/.claude/skills/<skill>` |
| `copilot` | `~/.copilot/skills/<skill>` |
| `gemini` | `~/.gemini/skills/<skill>` |
| `cursor` | `~/.cursor/skills/<skill>` |
| `windsurf` | `~/.codeium/windsurf/skills/<skill>` |
| `cline` | `~/.cline/skills/<skill>` |
| `roo` | `~/.roo/skills/<skill>` |
| `kilo` | `~/.kilo/skills/<skill>` |
| `opencode` | `$XDG_CONFIG_HOME/opencode/skills/<skill>` or `~/.config/opencode/skills/<skill>` |
| `amp` | `$XDG_CONFIG_HOME/agents/skills/<skill>` or `~/.config/agents/skills/<skill>` |
| `kiro` | `~/.kiro/skills/<skill>` |
| `qwen` | `~/.qwen/skills/<skill>` |

Accepted product-name aliases are `claude-code`, `github-copilot`,
`gemini-cli`, `roo-code`, `roocode`, `kilo-code`, `kilocode`, `open-code`,
`kiro-cli`, and `qwen-code`.

This list is intentionally based on native Agent Skills support: each target
documents a user-level `SKILL.md` discovery directory and loads skill bodies on
demand. Trail does not translate the suite into always-loaded rules for agents
without that contract. That keeps the installation portable, preserves
progressive disclosure, and avoids claiming support that cannot be tested as
Agent Skills.

| Skill | Focus |
| --- | --- |
| `trail-lanes` | Concurrent lanes, shared immutable environments, private writable state, gates, readiness, and merge preparation |
| `trail-workspace` | Recording, history, provenance, Trail branches, checkout, and explicit Git handoff |
| `trail-agent-tasks` | Managed task launch, review, validation, handoff, recovery, readiness, and apply |
| `trail-integrations` | Structured CLI, MCP, ACP relay, native hooks, and authenticated HTTP |
| `trail-recovery` | Diagnosis, conflicts, rewind, fsck, backup, and safe recovery |

The skills trigger independently. A lane worker is told not to recursively
launch another managed agent task, while `trail-agent-tasks` exposes launching
only when a user is explicitly operating the high-level task workflow.

The installer records a Trail ownership manifest per skill and is idempotent.
It inspects the complete suite before writing and refuses to replace an
unmanaged directory or locally edited installed files. Use `--force` only after
preserving intentional edits; use `--dry-run` to report each planned create,
update, or no-op action without changing files. Restart the agent after a
successful installation.

## Quick Start

### Set up an agent provider
Expand Down
53 changes: 0 additions & 53 deletions skills/use-trail/SKILL.md

This file was deleted.

4 changes: 0 additions & 4 deletions skills/use-trail/agents/openai.yaml

This file was deleted.

Loading
Loading