new-feature

new-feature is a command for coding agents from pablomarin/claude-codex-forge. It costs 0 tokens per session (19,562 once invoked), scanned B, a copy of fix-bug, MIT.

A mandatory workflow for developing a new feature. It coordinates several Claude Code plugins for planning, coding, debugging, and review.

In plain words
What is it for?
Use it to plan and implement features, run systematic debugging, review code, and prepare changes in a separate worktree.
Why use it?
It gives feature work a fixed sequence and checks that required tools are enabled before starting. It also requires an isolated worktree, a separate working copy of the repository.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/pablomarin/claude-codex-forge/new-feature
Clone the repo
git clone --depth 1 https://github.com/pablomarin/claude-codex-forge

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for new-feature

README.md
[![agentmods](https://agentmods.dev/badge/commands/pablomarin/claude-codex-forge/new-feature.svg)](https://agentmods.dev/commands/pablomarin/claude-codex-forge/new-feature)
Your own site
<a href="https://agentmods.dev/commands/pablomarin/claude-codex-forge/new-feature"><img src="https://agentmods.dev/badge/commands/pablomarin/claude-codex-forge/new-feature.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 19,562 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. Scan, not verified.
Origin 86% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.19562
Opus 5 $0.00000 $0.09781
Sonnet 5 $0.00000 $0.03912
Haiku 4.5 $0.00000 $0.01956

Measured 4d ago against content hash 391e239b2d99, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade B, and why

new-feature scanned grade B with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

[ -f .claude/playwright-dir ] && NODE_DIRS="$(cat .claude/playwright-dir) $NODE_DIRS"
Origin

This is a copy

86% identical to fix-bug — 654 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

commands/new-feature.md · 1,311 lines

How it starts

The opening of the file, as written. The whole thing — 1,311 lines — stays where its author put it; the contents beside it link to each section on GitHub.

New Feature Workflow

This workflow is MANDATORY. Follow every step in order. If any required command/skill fails with "Unknown skill", STOP and alert the user.

Required Plugins

This workflow requires the following plugins to be installed AND enabled:

Plugin Skills/Commands Used
superpowers@claude-plugins-official /superpowers:brainstorming, /superpowers:writing-plans, /superpowers:subagent-driven-development (default executor), /superpowers:executing-plans (headless mode), /superpowers:systematic-debugging
pr-review-toolkit@claude-plugins-official code-simplifier agent, code-reviewer agent, /pr-review-toolkit:review-pr

To enable plugins, add to ~/.claude/settings.json:

{
  "enabledPlugins": {
    "superpowers@claude-plugins-official": true,
    "pr-review-toolkit@claude-plugins-official": true,
    "frontend-design@claude-plugins-official": true
  }
}

Pre-Flight Checks

1. Create Isolated Workspace (MANDATORY)

Check if already in a worktree:

if [[ "$(pwd)" == *".worktrees/"* ]]; then
  echo "STATE: ALREADY_IN_WORKTREE"
else
  echo "STATE: NEEDS_WORKTREE"
fi

If ALREADY_IN_WORKTREE:

  • You're already isolated — continue with current workspace
  • Surface drift on the parent default branch (advisory; no auto-FF from inside a worktree)
# DRIFT-PREFLIGHT-ALREADY-BEGIN (byte-identical with commands/fix-bug.md — enforced by test-contracts.sh)
ROOT="$(git rev-parse --show-toplevel)"
LIB="$ROOT/.claude/hooks/lib/default-branch.sh"
[ ! -f "$LIB" ] && LIB="$ROOT/hooks/lib/default-branch.sh"
DEFAULT_BRANCH=$(bash "$LIB" 2>/dev/null) \
    || { DEFAULT_BRANCH="main"; echo "  ⚠ default-branch helper bailed; assuming 'main' (drift check may be wrong on non-main repos)" >&2; }
ALREADY_FETCH_OK=true
git fetch origin --quiet 2>/dev/null || ALREADY_FETCH_OK=false
# Behind-check: only if FETCH succeeded AND both refs exist. Skipping on fetch failure
# prevents reporting drift against a stale origin/* ref. Also guards rev-list exit-128.
if [ "$ALREADY_FETCH_OK" = "true" ] \
   && git rev-parse --verify "$DEFAULT_BRANCH" >/dev/null 2>&1 \
   && git rev-parse --verify "origin/$DEFAULT_BRANCH" >/dev/null 2>&1; then
  BEHIND=$(git rev-list --count "$DEFAULT_BRANCH..origin/$DEFAULT_BRANCH" 2>/dev/null || echo "")
  if [[ "$BEHIND" =~ ^[0-9]+$ ]] && [ "$BEHIND" -gt 0 ]; then
    echo "  ⚠ Parent '$DEFAULT_BRANCH' is $BEHIND commits behind origin (skipping auto-FF from worktree)"
  fi
fi
# DRIFT-PREFLIGHT-ALREADY-END

Read the full file on GitHub · 1,311 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 1,311 lines · 0 tokens per session scan B 391e239b2d99

Subscribe to this mod's changes

new-feature is a command published in the GitHub repository pablomarin/claude-codex-forge (5 stars, last pushed 6d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 19,562 tokens. A static security scan graded it B with 1 finding (reads agent configuration directories). It is 86% identical to fix-bug, differing in 654 lines, and is treated as a copy.