comment-body-literal-path

comment-body-literal-path is a command for Claude Code from rjwalters/kicad-tools. It costs 0 tokens per session (1,169 once invoked), scanned A, original, MIT.

A warning about GitHub CLI commands that treat --body @path as literal text instead of reading the file at that path.

In plain words
What is it for?
Use it when posting comments or reviews with gh issue comment, gh pr comment, or gh api, especially when the message is stored in a temporary file.
Why use it?
It prevents issue comments and pull-request reviews from being posted as an unusable file path instead of their intended contents.

Command for Claude Code

Written for Claude Code: installed under .claude/. Also seen: mentions subagents.

Good fit Use it when posting comments or reviews with gh issue comment, gh pr comment, or gh api, especially when the message is stored in a temporary file.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/rjwalters/kicad-tools/comment-body-literal-path
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.

Clone the repo
git clone --depth 1 https://github.com/rjwalters/kicad-tools

Made for: Claude Code.

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 comment-body-literal-path

README.md
[![agentmods](https://agentmods.dev/badge/commands/rjwalters/kicad-tools/comment-body-literal-path/github.svg)](https://agentmods.dev/commands/rjwalters/kicad-tools/comment-body-literal-path)
Your own site
<a href="https://agentmods.dev/commands/rjwalters/kicad-tools/comment-body-literal-path"><img src="https://agentmods.dev/badge/commands/rjwalters/kicad-tools/comment-body-literal-path/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for comment-body-literal-path

Your own site · 80×15
<a href="https://agentmods.dev/commands/rjwalters/kicad-tools/comment-body-literal-path"><img src="https://agentmods.dev/badge/commands/rjwalters/kicad-tools/comment-body-literal-path.svg" alt="Reviewed on agentmods" width="80" 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 1,169 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found 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.1 $0.00000 $0.01169
Opus 5.5 $0.00000 $0.00468
Sonnet 5.5 $0.00000 $0.00234
Haiku 4.5 $0.00000 $0.00117

Measured 1mo ago against content hash f379df19ff4e, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

comment-body-literal-path scanned grade A with 0 findings 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 1mo 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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/loom/comment-body-literal-path.md · 78 lines

How it starts

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

--body @path Does NOT Expand — It Posts the Literal String (canonical)

Single canonical copy; role prompts' short pointers refer here.

If a comment/review body you're posting (via gh issue comment, gh pr comment, or gh api ... comments) lives in a scratch/scratchpad file, do not pass it as --body @path. Unlike some shells' @file conventions, gh pr comment --body @path and gh issue comment --body @path do not read the file — they post the literal text @path as the comment. A real incident (PR #4457) lost an entire changes-requested review this way (the body was the string @/private/tmp/.../review.md; the file was overwritten before anyone caught it). It recurred again later via gh api ... -f body=@path (-f/--raw-field never expands @path either) — see #5252. The stdin spelling fails identically: --body @- and -f body=@- post the literal @- (#9258: a PR merged on an approval whose whole body was @-). Only gh api ... -F body=@- reads stdin; post-verdict.sh takes --body-file -.

❌ POSTS THE LITERAL STRING "@path" — NOT THE FILE CONTENTS
   gh pr comment 123 --body @/tmp/review-123.md
   gh pr comment 123 --body "@/tmp/review-123.md"
   gh issue comment 123 --body @/tmp/comment-123.md
   gh pr comment 123 --body @-        (stdin spelling: still the literal "@-")

❌ ALSO POSTS THE LITERAL STRING — a variable does NOT change what the flag does
   REVIEW_FILE="@/tmp/review-123.md"; gh pr comment 123 --body "$REVIEW_FILE"

❌ ALSO POSTS THE LITERAL STRING — on `gh api`, only -F/--field expands @path
   gh api repos/{owner}/{repo}/issues/123/comments -f body=@/tmp/review-123.md

✅ USE ONE OF THESE INSTEAD
   gh pr comment 123 --body "$(cat <<'EOF'
   ... review prose ...
   EOF
   )"
   gh pr comment 123 --body-file /tmp/review-123.md
   gh api repos/{owner}/{repo}/issues/123/comments -F body=@/tmp/review-123.md

Prefer the heredoc for a short/dynamic body and --body-file <path> for one that lives in a file (gh api ... -F body=@path also reads it; -f does not). --body/-b takes literal text only. After posting, re-fetch the comment (gh pr view <number> --comments) to confirm it renders your prose, not a path string.

Why <<'EOF' must stay quoted: .loom/docs/comment-body-heredoc-quoting.md.

Read the full file on GitHub · 78 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. 1mo ago Changed · -1 lines f379df19ff4e
  2. 3mo ago First seen · 79 lines · 0 tokens per session scan A 2fa0de1fb202

Subscribe to this mod's changes

comment-body-literal-path is a command published in the GitHub repository rjwalters/kicad-tools (77 stars, last pushed 15d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,169 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

comment-body-literal-path compared with commands from other repositories

comment-body-literal-path next to 6 commands from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
comment-body-literal-pathrjwalters/kicad-toolsCommand7715d agoMITA0Claude Code
merge-conflict-analysisrjmurillo/ai-agentsCommand50todayApache-2.0A0GitHub Copilot
release-notesOpenHands/extensionsCommand190todayMITA44Claude Code
commitechoVic/blade-codeCommand18116d agoMITA8Claude Code
repo-audittractorjuice/arc-kitCommand2.3kyesterdaynoneA29Claude Code
codex-reviewoalders/kitchen-sinkCommand5todayMITA41Claude Code
releaseparuff/uFawkesAICommand2yesterdayMITA39Claude Code