driftless

Quick Start

Get started with driftless in under 5 minutes.

Prerequisite

driftless requires Claude Code CLI to be installed and authenticated. The CLI uses Claude Code to read your tests and generate documentation.

Installation

Run the init command in your project root:

npx @driftless-ai/cli@latest init

The CLI auto-detects your test framework (Playwright, Cypress, TestCafe, Detox, WebDriverIO, or Nightwatch) and walks you through six configuration prompts:

  1. Test file glob pattern — which test files to analyze (auto-populated from your detected framework)
  2. Output directory — where generated docs are written (default: docs/training)
  3. Documentation framework — Plain Markdown, Fumadocs MDX, or Docusaurus MDX
  4. Capabilities to enable — Doc Generator, E2E Writer, or both
  5. Skills directory — where skill definition files are stored (default: .skills)
  6. Auto-update preference — whether the CLI should self-update on launch

A .driftless.json config file is created in your project root. See the init walkthrough for a detailed breakdown of each prompt and what happens after you answer them.

How It Works

When you run driftless init with the Doc Generator capability enabled, driftless reads your end-to-end test files and generates user-facing training documentation. It also installs skill files that teach Claude Code how to write and maintain docs in your project's conventions.

When your tests change in a pull request, the installed GitHub Actions workflow detects which docs are stale and updates them automatically.

GitHub Actions

driftless init scaffolds up to two GitHub Actions workflows depending on your selected capabilities:

  • Driftless Doc Update — detects stale documentation when tests change in a PR and updates it
  • Driftless Test Generation — detects new user-facing flows in a PR and generates missing e2e tests

Both workflows use claude-code-action and require an ANTHROPIC_API_KEY secret in your repository. See the GitHub Actions guide for setup details and operational edge handling.

Next Steps