jedarden

Claude Print — Development skill for Claude Code

Development community

Drop-in replacement for claude -p that drives the interactive TUI via PTY, preserving subscription billing.

How to install Claude Print

This entry records only its repository, not the path inside it, so there is no exact command to give. Open jedarden/claude-print and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

What Claude Print does

Drop-in replacement for claude -p that drives the interactive TUI via PTY, preserving subscription billing.

Alternatives in Development

  • Code Simplifier — Simplify code while preserving functionality 14k ★
  • Ccusage — CLI for analyzing Claude Code/Codex usage from local JSONL files 11.8k ★
  • Mono Color Skill — One-ink editorial print image skill — warm paper, halftone photography, active negative space, and restrained 3k ★

README

claude-print

Drop-in replacement for `claude -p` (print/headless mode) that drives the Claude Code interactive TUI via PTY — keeping sessions on the unlimited subscription pool rather than the per-token Agent SDK credit pool.

Why this exists

Anthropic routes `claude -p` (headless/SDK mode) through a separate Agent SDK credit pool ($100–$200/month on Max plans). Only the interactive TUI (`cc_entrypoint=cli`) draws from the unlimited subscription.

The billing path is determined by an `isatty` check inside the `claude` binary: when stdout is a TTY, the session is tagged `cc_entrypoint=cli` and billed against the subscription. When stdout is a pipe (as with `claude -p`), it becomes `cc_entrypoint=sdk-cli` and draws from the credit pool instead.

`claude-print` allocates a PTY, drives the interactive TUI over it, auto-dismisses the trust dialog, injects the user prompt via bracketed paste, waits for the Stop hook via a FIFO, reads the JSONL transcript, and emits clean stdout output — giving callers `claude -p` wire-compatible output while billing against the subscription.

Prerequisites

  • Claude Code must be installed and authenticated. See claude.ai/code.
  • An active Claude subscription (Pro or Max plan) is required. The whole point is to bill against subscription, not credits.
  • HOME must be set to a non-empty value for the user running claude-print. Claude Code configuration, trust state, and transcripts are resolved beneath this directory.
  • Linux only. PTY support requires POSIX — no Windows ConPTY.

Install

sh install.sh

`install.sh` downloads a pre-built static musl binary from GitHub Releases (`jedarden/claude-print`), runs `--check` to verify the setup, and copies `claude-print.yaml` to `~/.needle/agents/` if NEEDLE is present.

Set `SKIP_MOCK_CLAUDE=1` to skip the `mock_claude` test fixture download.

Build from source

git clone https://github.com/jedarden/claude-print
cd claud