claudemd-statusline

claudemd-statusline is a command for Claude Code from sdsrss/claudemd. It costs 0 tokens per session (1,427 once invoked), scanned B, original, MIT.

A command that adds a terminal-style status line to Claude Code. The line can show the user, computer, folder, Git branch, model, context usage, and time-based quota usage.

In plain words
What is it for?
Use it to detect, install, refresh, inspect, or remove the claudemd status line, with an optional force mode for taking over a slot owned by another provider.
Why use it?
It puts useful session and usage information in one visible place, while checking whether another status line already owns the configuration.

Command for Claude Code

Written for Claude Code: ${CLAUDE_PLUGIN_ROOT} variable. Also seen: reads .claude/ paths.

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the claudemd plugin — 16 commands, 6 hooks shipped together

Good fit Use it to detect, install, refresh, inspect, or remove the claudemd status line, with an optional force mode for taking over a slot owned by another provider.

Compare 6 commands from other repositories ↓
Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add sdsrss/claudemd
Claude Code
/plugin install claudemd

Made for: Claude Code.

Or install claudemd, the plugin that ships this one along with the rest of its 16 commands, 6 hooks.

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 claudemd-statusline

README.md
[![agentmods](https://agentmods.dev/badge/commands/sdsrss/claudemd/claudemd-statusline.svg)](https://agentmods.dev/commands/sdsrss/claudemd/claudemd-statusline)
Your own site
<a href="https://agentmods.dev/commands/sdsrss/claudemd/claudemd-statusline"><img src="https://agentmods.dev/badge/commands/sdsrss/claudemd/claudemd-statusline.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 1,427 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. 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.01427
Opus 5 $0.00000 $0.00714
Sonnet 5 $0.00000 $0.00285
Haiku 4.5 $0.00000 $0.00143

Measured 8d ago against content hash 2cf2074b0112, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade B, and why

claudemd-statusline 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 8d 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.

description: Register claudemd's PS1-style statusLine (user@host:path (branch) model [ctx:N% · 5h:N% · 7d:N%] — context / 5h quota / weekly quota, all used %) in ~/.claude/settings.json. Use when (1) the user asks to add
commands/claudemd-statusline.md · 48 lines

How it starts

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

Usage: /claudemd-statusline | /claudemd-statusline --force | /claudemd-statusline check | /claudemd-statusline remove

Step 0 — detect (deterministic, no writes)

Run: node ${CLAUDE_PLUGIN_ROOT}/scripts/statusline-adopt.js detect --json

Branch on verdict:

  • absent → slot is free. Continue to Step 1 (adopt).
  • claudemd → already configured. Report the stable path ~/.claude/claudemd-statusline.sh and dest.matchesShipped. If false, offer to re-run adopt (refreshes the renderer copy). STOP unless the user wants a refresh.
  • foreign → another provider owns the slot (report current). Do NOT write. Tell the user their existing statusline is untouched and that /claudemd-statusline --force will take it over (saving the current command so remove can restore it). Continue to Step 1 ONLY if the user passed --force.
  • host → the slot is owned by a composite host (host, e.g. code-graph) that renders multiple providers. Do NOT clobber it. Run detect --json and read providers + guestRegistered:
    • guestRegistered: true → claudemd is already a segment. Report and STOP unless the user wants a refresh (re-run adopt).
    • guestRegistered: false → claudemd will register as a guest so both segments show (claudemd | code-graph). Read the psCandidates array from detect --json — each entry is a hand-made PS1 (a bash script under ~/.claude/ that isn't a plugin, e.g. user-ps1) claudemd can supersede. If it is non-empty, list those ids and ASK: supersede one (adopt --supersede=<id>, saved for restore) or keep both (adopt). Continue to Step 1.

check mode (no writes)

Run Step 0. Report verdict, current, and whether ~/.claude/claudemd-statusline.sh exists and matches the shipped renderer (dest.matchesShipped). STOP.

remove mode

Show the transition first: run detect --json; if verdict is claudemd, state what settings.statusLine will become (restored prior command if one was saved, else removed) and that ~/.claude/claudemd-statusline.sh will be deleted. If verdict is host and guestRegistered, remove unregisters claudemd from the host's registry (restoring a superseded provider if one was saved) and deletes the renderer; the host keeps the slot. Then run: node ${CLAUDE_PLUGIN_ROOT}/scripts/statusline-adopt.js remove --json Report the action (removed / restored / unregistered / not-ours). For unregistered, cite restored if any. If not-ours, nothing was changed.

Read the full file on GitHub · 48 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. 8d ago First seen · 48 lines · 0 tokens per session scan B 2cf2074b0112

Subscribe to this mod's changes

claudemd-statusline is a command published in the GitHub repository sdsrss/claudemd (2 stars, last pushed today), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,427 tokens. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.