# Long haul

> Long haul is an open-source agent skill for developer tools. Drives an agent through a long, measurable goal loop with explore-or-exploit rounds. It is available on Claude Code.

- **Kind:** Skill
- **Pricing:** Open source
- **Platforms:** Claude Code
- **Website:** https://github.com/ccomkhj/skills/tree/main/long-haul/skills/long-haul
- **Repository:** https://github.com/ccomkhj/skills
- **GitHub stars:** 10
- **License:** MIT
- **Skill name:** long-haul
- **Collection:** https://github.com/ccomkhj/skills
- **Categories:** [developer tools](https://ai-powered.com/categories/developer-tools)
- **Listing updated:** 2026-12-02

## About

Long-haul coordinates a multi-turn run that keeps an agent working toward a verifiable target until it holds. It moves through phases: sharpening a spec (grilling it first if the request is vague), turning that spec into a completion condition for Claude Code's /goal command, then running one round per turn in a git worktree. Each round either explores a fresh approach from the base branch or refines the current best attempt, and only measured improvements are kept.

The skill keeps its state in a hidden folder inside the target repository, tracking the current phase, round count, stall counter and incumbent so a session can resume cleanly. It includes preflight checks for git, the GitHub CLI, the /goal version and unattended-run readiness, and it flags any toolbox step that costs money or touches production before the loop begins. It also has two human approval gates: one before the goal is activated and one before a pull request is opened.

It expects a Claude Code session with git and, for the final step, an authenticated GitHub CLI. Helper scripts are written in bash, and the skill is aimed at a single developer driving one agent through a spec.

## When your agent uses it

> Auto-chaining orchestrator for a solo long-horizon goal loop. Sharpen a spec (grill it if vague), forge a /goal completion condition, then haul toward it turn after turn in a git worktree — each turn deciding explore (a fresh approach off the base) vs exploit (refine the incumbent), keeping only measured wins, until the goal holds. Use when the user wants one agent driven relentlessly toward a verifiable target over many turns — not a one-shot edit. Reach for it when the user says "keep working until", "loop until done", "long haul", or hands a spec to be built to completion.

## What it can access

From a static check of the files on GitHub; nothing was run.

- [Runs shell scripts](https://github.com/ccomkhj/skills/tree/HEAD/long-haul/skills/long-haul)
- [No network calls found in its scripts](https://github.com/ccomkhj/skills/tree/HEAD/long-haul/skills/long-haul)
- [License: MIT](https://github.com/ccomkhj/skills/tree/HEAD/long-haul/skills/long-haul)

## Features

- **Spec sharpening:** Turns a rough ask into a defined spec with a checkable success signal and a declared toolbox.
- **Completion condition forging:** Builds a /goal-ready completion condition from the spec and waits for user approval before starting.
- **Explore or exploit rounds:** Each turn chooses between a fresh approach off the base and refining the current best attempt.
- **Measured incumbent ratchet:** Keeps an attempt only when it beats the incumbent, and stops after repeated stalls.
- **Preflight readiness checks:** Verifies git, the GitHub CLI, the /goal version and unattended-run settings before the loop starts.
- **Pull request wrap-up:** Summarizes goal results against achieved output and opens a pull request after confirmation.

## Good for

- Keep working on a feature until its test suite passes
- Build a spec to completion over many agent turns
- Drive a refactor toward a measurable target without manual restarts
- Loop an agent on a task until a stated check output proves it is done
- Resume an interrupted multi-round build from saved state

## Install

### Claude Code

This skill ships in the `long-haul` plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):

```sh
/plugin marketplace add ccomkhj/skills
/plugin install long-haul@ccomkhj-skills
```

Or copy only this skill to `~/.claude/skills/long-haul`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ccomkhj/skills.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/long-haul &&
cp -R "$tmp/long-haul/skills/long-haul" ~/.claude/skills/long-haul &&
rm -rf "$tmp"
```

For one project only, put the folder in `.claude/skills/long-haul` inside it instead.

### Codex

Copy the skill folder to `~/.agents/skills/long-haul` to use it in every repository:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ccomkhj/skills.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/long-haul &&
cp -R "$tmp/long-haul/skills/long-haul" ~/.agents/skills/long-haul &&
rm -rf "$tmp"
```

For one repository only, put the folder in `.agents/skills/long-haul` inside it instead.

### Cursor

Copy the skill folder to `~/.cursor/skills/long-haul` to use it in every project:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ccomkhj/skills.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/long-haul &&
cp -R "$tmp/long-haul/skills/long-haul" ~/.cursor/skills/long-haul &&
rm -rf "$tmp"
```

For one project only, put the folder in `.cursor/skills/long-haul` inside it instead.

### Gemini CLI

Run in a terminal (add `--scope workspace` to install it for the current workspace only):

```sh
gemini skills install https://github.com/ccomkhj/skills.git --path long-haul/skills/long-haul
```

Or copy the folder to `~/.gemini/skills/long-haul` yourself.

### VS Code

For GitHub Copilot in VS Code, copy the skill folder to `~/.copilot/skills/long-haul`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ccomkhj/skills.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/long-haul &&
cp -R "$tmp/long-haul/skills/long-haul" ~/.copilot/skills/long-haul &&
rm -rf "$tmp"
```

For one project only, put the folder in `.github/skills/long-haul` inside it instead.

### Other agents

Get the folder:

```sh
git clone --depth 1 https://github.com/ccomkhj/skills.git
```

Then copy `skills/long-haul/skills/long-haul` into your agent's skills folder as `long-haul`. Agents that support SKILL.md read one folder per skill.

## FAQ

### What do I need to run Long haul?

Claude Code v2.1.139 or later for /goal, git, and for the final step an authenticated GitHub CLI with push permission to the repository.

### Does Long haul change my repository directly?

Work happens in a git worktree and state lives in a hidden .longhaul folder added to .gitignore. Changes reach the repository through a branch and pull request, which only opens after you confirm.

### When does Long haul start running?

It starts only after you approve the generated completion condition and run the /goal line yourself.

### Which tools does Long haul use?

The skill's helper scripts are written in bash, and the skill relies on git worktrees and the GitHub CLI.

### How do I install Long haul in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/long-haul to use it in all your projects, or to .claude/skills/long-haul in one project. Or install the long-haul plugin, which includes it: /plugin marketplace add ccomkhj/skills, then /plugin install long-haul@ccomkhj-skills.

### Does Long haul run scripts?

Yes. It runs shell scripts. No network calls were found in its scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

### Which AI agents can use Long haul?

Claude Code. It reads skills in the SKILL.md format; the install steps on this page show where to put the folder.

### What are the best alternatives to Long haul?

The closest alternatives to Long haul are Haul loop, Haul goal, Haul ship, Dual haul and Spec driven dev v2.

## Where this comes from

- Description: from the skill's own SKILL.md.

## Alternatives

- [Haul loop](https://ai-powered.com/skills/haul-loop): Haul loop is an open-source agent skill for developer tools.
- [Haul goal](https://ai-powered.com/skills/haul-goal): Haul goal is an open-source agent skill for developer tools.
- [Haul ship](https://ai-powered.com/skills/haul-ship): Haul ship is an open-source agent skill for developer tools.
- [Dual haul](https://ai-powered.com/skills/dual-haul): Dual haul is an open-source agent skill for developer tools.
- [Spec driven dev v2](https://ai-powered.com/skills/spec-driven-dev-v2): Spec driven dev v2 is an open-source agent skill for developer tools.
- [Goal prompt](https://ai-powered.com/skills/goal-prompt): Goal prompt is an open-source agent skill for ai models and llm tooling.
- [Dual goal](https://ai-powered.com/skills/dual-goal): Dual goal is an open-source agent skill for developer tools.
- [Dual loop](https://ai-powered.com/skills/dual-loop): Dual loop is an open-source agent skill for developer tools.

---
Source: https://ai-powered.com/skills/long-haul
