DEV Community

developerz.ai
developerz.ai

Posted on

Automating the Full PR Lifecycle with Claude Task Master

Automating the Full PR Lifecycle with Claude Task Master

If you use Claude Code daily, you know the loop: plan a feature, write code, run tests, commit, push, open a PR, wait for CI, fix failures, address review comments, merge. Repeat.

Claude Task Master (CLI: claudetm) automates that entire loop. Give it a goal and it:

  1. Plans - reads the codebase, creates a task list organized by PRs, defines success criteria up front
  2. Executes - works through each task: makes changes, runs tests, commits, pushes
  3. Creates PRs - all work flows through pull requests, never direct commits
  4. Handles CI - waits for checks, fixes failures, addresses review comments
  5. Merges - auto-merges when approved (configurable)
  6. Verifies - confirms every success criterion is actually met
  7. Adapts - accepts dynamic plan updates via its mailbox system while still working

State That Survives Interruptions

The key difference from a simple script: Task Master persists state between sessions. Close your laptop, lose power, hit a rate limit - the task resumes exactly where it left off. The mailbox system lets you send plan updates mid-execution via REST API, MCP, or CLI.

Running Multiple Subscriptions in Parallel

By default claudetm uses your global Claude Code session. Profiles let you run isolated instances:

  • OAuth profiles - each gets its own config home at ~/.claudetm/profiles/<name>/, so two Claude subscriptions never clobber each other
  • API-key profiles - inject ANTHROPIC_API_KEY and ANTHROPIC_BASE_URL directly (works with Anthropic API or OpenRouter)

This means you can run multiple autonomous agents against the same repo or different ones, each with its own credentials.

Building On Top

The REST API, MCP server, and HMAC-signed webhooks expose the same lifecycle programmatically. Our own claudetm merge-pr command uses this - PRs #147-#150 in our repo were merged this way.

Quick Start

uv tool install claude-task-master
claude
/login
cd your-project
claudetm start "Add user authentication with tests"
Enter fullscreen mode Exit fullscreen mode

Requires Python >= 3.10, authenticated Claude CLI, and authenticated GitHub CLI.

MIT licensed. Free on PyPI and Docker.

https://github.com/developerz-ai/claude-task-master

ClaudeCode #AIAgents #DevTools #Automation #OpenSource

Top comments (0)