ClaudeModsClaude Code 模组目录
☰
● 0 人在线 · 浏览 0 次
+ 提交作品
← 返回作品集
GitHub 仓库 · 其他

overalls — Claude Code 插件 · ClaudeMods

回报这个作品这是你的作品?认领

在 ClaudeMods 了解这款 Claude Code 插件,查看原始来源与所需权限。 提示框上方的状态栏:上下文天气、用量上限,以及 Ponytail 和 Caveman 等级

TTroepster@Troepster
原帖图片1
已翻译

关于这个 mod

overalls

在提示框上方绘制状态栏的 Claude Code mod:显示上下文窗口的实时“天气预报”、已使用的用量上限,以及 Ponytail 和 Caveman 当前的运行等级。

桌面版中的状态栏:预报、迷你趋势图、上一回合变化、用量上限、会话费用及 Ponytail、Caveman 下拉菜单,右侧有 ⚙

上下文超过 75% 时(且 Claude 不在回合执行途中),状态栏会出现 Compact 按钮。

组件在一行放不下时,会整体移到第二行;Compact 和 ⚙ 留在第一行右侧。

安装

在 Claude Code 终端中:

/plugin marketplace add Troepster/overalls
/plugin install overalls@overalls
/reload-plugins

或从任何 shell 执行,也适用于桌面版(新会话会加载):

claude plugin marketplace add Troepster/overalls
claude plugin install overalls@overalls

状态栏没有出现时,请开始新会话或重启 Claude Code。

更新方式:在 Claude Code 中执行 /plugin marketplace update overalls,或从 shell 执行:

claude plugin marketplace update overalls
claude plugin update overalls@overalls

Ponytail 和 Caveman 都是可选的。未安装 Caveman 时不显示其组件;未安装 Ponytail 时,其组件会显示 not installed,直到你将它设为 off。无论哪种情况,⚙ Config 框都会提供安装选项。

mod 在 Claude Code 内运行,具有与 Claude Code 相同的访问权限,因此安装前请阅读 hooks/register.tsx。

设置

各设置在 Claude Code 配置菜单的 overalls 下各占一行,更改任一设置会重新加载 mod。/overalls 命令可从提示框设置,也适用于没有 /config 的桌面版:

/overalls weather minimal
/overalls ponytail off
/overalls            (shows the current values)

状态栏上方打开的 Config 框:各设置的所有选项分成两列,当前选项有勾选;下方状态栏换行到第二行

状态栏右侧的 ⚙ 会在上方打开 Config 框,列出每个设置的所有选项,当前选项会打勾;点击选项即可设置,并实时在状态栏看到变化。再点一次 ⚙ 即可关闭。将鼠标停在 Config 框中的设置名称上,可看到一行说明。

点击预报本身(Showers,或 minimal 时的 67%),会让天气详细程度按 minimal → normal → full 循环切换;off 要在 Config 框中设置。

若 mod 有 /config 设置行(终端),/overalls 会设置该行。若没有(桌面版),则把选择存到 mod 自己的存储中;该选择在每个会话都优先于 /config 的值,直到你在有该设置行的会话用 /overalls 设置同一项。

| 设置 | 值 | 默认 | 功能 | |---|---|---|---| | 天气详细程度 | off · minimal · normal · full(输入值;其他值视为 full) | full | 显示多少预报内容 | | Ponytail 等级 | off · icon · text(输入值;其他值视为 icon,旧的 on/off 值视为 icon/off) | icon | 在标志或 ponytail: 字样后显示 Ponytail 是否安装及其等级 | | Caveman 模式 | off · icon · text(输入值;其他值视为 icon) | icon | 安装后,在 🪨 或 caveman: 字样后显示 Caveman 模式 | | 提供 megacave | on · off | off | 在下拉菜单列出 Caveman 的文言文模式(megacave);在 Config 框中与 Caveman 同行 | | 用量上限 | on · off | on | 显示 5 小时和每周上限已用多少(仅订阅适用) | | 上限重置 | on · off | on | 显示各上限距离重置多久(5h 42% ↻1h20m);在 Config 框中与 Limits 同行 | | 额度耗尽 | off · warn · always(输入值;其他值视为 warn) | warn | 按最近一小时的使用速度,警告额度将在重置前耗尽:⚠1h40m 显示琥珀色,少于 30 分钟时显示红色。always 也会对不会提前耗尽的额度显示 ✓ lasts。需先积累 10 分钟样本及 2 个百分点的变化。显示于各上限后;关闭上限显示时可单独显示(5h ⚠1h40m) | | 会话费用 | on · off | off | 显示此会话当前累计的费用 | | MCP 警告 | on · off | on | MCP 服务器或连接器失败、或需重新登录时警告 | | 运行中的智能体 | on · off | on | 子智能体运行时显示 ⧗ 2 agents;点击可列出类型和任务 | | 剩余回合 | on · off | on | 显示 ⌛ ~6 turns:按最近五个有增长的回合的平均增量,估计还能容纳多少回合(从 3 起显示红色) | | 工具拒绝 | on · off | on | 你、钩子、权限规则或自动模式分类器拒绝工具调用时显示 ⛔ 2 denied;点击可列出,并提供 Dismiss |

各天气等级显示的内容:

| 等级 | 状态栏 | |---|---| | minimal | ☂ 67% | | normal | ☂ Showers 67% · 134.4k / 200k | | full | normal 加上最近 12 回合的迷你趋势图及上一回合以来的变化 | | off | 不显示(若启用 Ponytail,其区段仍会显示) |

Ponytail 检测

<picture> <source media="(prefers-color-scheme: dark)" srcset="assets/ponytail-logo-dark.png"> <img src="assets/ponytail-logo.png" width="110" alt="Ponytail, the lazy senior dev"> </picture>
  • 已安装: enabledPlugins 中有已启用的 ponytail@… 条目。否则状态栏会在标志旁显示 not installed。
  • 等级: 属于当前会话。Ponytail 所有会话共用一个等级文件,无法指出这个会话的等级;Overalls 改按 Ponytail 规则逐会话跟踪:
    • 新会话及压缩后(Ponytail 重新启动)从 Ponytail 默认等级开始:优先 $PONYTAIL_DEFAULT_MODE,其次是 config.json($XDG_CONFIG_HOME/ponytail/ 或 ~/.config/ponytail/)中的 defaultMode,最后是 full。
    • 输入 /ponytail <level>(或 /ponytail:ponytail <level>)、/ponytail-review、stop ponytail 和 normal mode 时更新等级。 其他会话的切换不会改变这条状态栏。
  • 切换: 从显示等级的下拉菜单选择,通过 Ponytail 自己的 /ponytail <level> 命令切换(移动端没有下拉菜单,点击按 ultra → full → lite → off 切换)。

安装 Ponytail 或 Caveman

尚未安装的项目会在 ⚙ Config 框的对应行提供 Install 按钮。mod 无法安装插件,因此会把请求输入提示框,例如:

Install the caveman Claude Code plugin: run `claude plugin marketplace add JuliusBrussee/caveman` then `claude plugin install caveman@caveman`.

发送后,Claude 会执行两条命令,各自经过通常的权限提示。插件钩子从下一个会话开始生效。

Caveman

  • 已安装: enabledPlugins 中有已启用的 caveman@… 条目;否则不显示。
  • 模式: 属于当前会话。Caveman 将各会话的模式存于 Claude 配置目录的 .caveman-sessions/<session id>.mode,状态栏读取此文件。没有自己文件的会话(在 Caveman 安装前启动)显示 off;共享的 .caveman-active 记录任何窗口最后设置的模式,只在没有会话 id 时读取。
  • 切换: 从下拉菜单选择模式(ultracave、caveman、off;启用 Offer megacave 时也包含以文言文回答的 megacave;移动端点击循环切换),通过 Caveman 自己的 /megacave、/ultracave、/caveman、/caveman off 命令完成。

MCP 警告

Claude Code 不向 mod 提供 MCP 服务器列表或状态,因此状态栏从 Claude 自己的工具调用获知问题:

  • mcp__<server>__… 调用登录或连接失败(参数错误不算),以及
  • ToolSearch 报告失败的服务器。

状态栏随后显示 ⚠ 2 MCP errors。点击会在上方打开 MCP errors 框(类似 Config 框,同时只能打开一个)。每台服务器各占一行:名称、sign in 或 failed、Claude 看到的错误,以及:

  • Reconnect:claude.ai 连接器会打开 Customize → Connectors。在桌面版直接于应用内打开(claude://claude.ai/customize/connectors);CLI 或网页版则打开 https://claude.ai/customize/connectors。其他服务器在终端使用 /mcp;桌面版的 /mcp 只会列出服务器,因此会提示从终端会话登录。
  • Dismiss 和 Dismiss all

服务器在下次调用成功或被忽略后会从列表移除。它在首次失败时才被发现,不会提前检测。

数据与访问

Overalls 不发出网络请求,也不发送任何数据。所有操作都留在你的 Claude Code 会话内:

  • 每回合后读取会话的上下文窗口用量($.session.usage())
  • 读取 Claude Code 配置,查看 Ponytail 是否启用
  • 对应组件开启时读取会话的用量上限百分比、重置时间及费用($.session.usage()),并读取时钟计算重置倒计时
  • 智能体组件开启时读取会话的子智能体列表($.agent.list():类型、任务、状态)
  • 每 30 秒重绘状态栏以更新倒计时与智能体数量;每次重绘记录用量上限百分比($.session.usage()),在会话内存保留最近一小时的数据,推算何时耗尽
  • 读取 Claude Code 配置查看 Caveman 是否启用;若启用,读取当前会话 id,以及 Claude 配置目录中的模式文件 .caveman-sessions/<session id>.mode(没有会话 id 时用 .caveman-active)
  • 读取 Ponytail 的 config.json 获取默认等级,以及 PONYTAIL_DEFAULT_MODE、XDG_CONFIG_HOME、CLAUDE_CONFIG_DIR、HOME 环境变量
  • 读取每个发送的提示,只识别 Ponytail 命令(/ponytail …、stop ponytail、normal mode),除了等级不保留其他内容
  • 在会话状态中保留最近 12 次读数与 Ponytail 等级,会话结束即消失
  • 只有你从状态栏选择时才切换 Ponytail 等级或 Caveman 模式:执行 /ponytail <level> 或 Caveman 对应模式命令,就像你亲自输入一样(Claude 也会像读取你输入的内容一样读取);若无法执行,就输入提示框
  • 只有点击 Config 框的 Install 才把安装请求输入提示框;必须发送并批准 Claude 的命令才会安装
  • 读取 Claude 调用的每个工具名称;若被你、钩子、权限规则或自动模式分类器拒绝,就在会话状态中保留工具名称及原因前 100 字符,直到你忽略
  • 读取 Claude 调用的每个 MCP 工具名称、失败时的错误文本,以及 ToolSearch 返回的失败服务器列表;只保留各失败服务器名称、需登录或失败的状态,以及错误前 100 字符。只有在终端点击 Reconnect 才执行 /mcp
  • MCP errors 框打开时读取 CLAUDE_CODE_ENTRYPOINT,区分桌面版、CLI 与网页版;桌面版点击连接器的 Reconnect 会将 claude://claude.ai/customize/connectors 交给系统打开工具(macOS 的 open、Linux 的 xdg-open、Windows 的 cmd /c start),在应用内打开页面
  • 只有点击 Compact 按钮才压缩对话;Claude Code 不允许插件压缩时(桌面版),点击会代你执行 /compact,若无法执行就输入提示框
  • 只有执行 /overalls weather …、/overalls ponytail …(及其他命令)时才更改自己的设置,或选择…

安装

请先查看作者 README 确认 marketplace 和插件名称;命令可能随仓库结构改变。

claude plugin marketplace add Troepster/overalls
claude plugin install overalls
原文 / README

overalls

A Claude Code mod that draws a status band above the prompt: a live "weather forecast" of the context window, how much of your usage limits is spent, and the level Ponytail and Caveman are running at.

The band in the desktop app: forecast, sparkline, last-turn change, usage limits, session cost, and the Ponytail and Caveman dropdowns, with ⚙ at the right

Once the context passes 75% (and Claude isn't mid-turn), a Compact button appears in the band.

Where the widgets don't fit on one row, they wrap whole onto a second, while Compact and ⚙ stay at the right of the first.

Install

In the Claude Code terminal:

/plugin marketplace add Troepster/overalls
/plugin install overalls@overalls
/reload-plugins

Or from any shell, which also covers the desktop app (new sessions pick it up):

claude plugin marketplace add Troepster/overalls
claude plugin install overalls@overalls

If the band doesn't appear, start a new session or restart Claude Code.

To update: /plugin marketplace update overalls in Claude Code, or from a shell:

claude plugin marketplace update overalls
claude plugin update overalls@overalls

Ponytail and Caveman are optional. Without Caveman its widget doesn't show; without Ponytail its widget reads not installed until you set it to off. Either way, the ⚙ Config box offers to install them.

A mod runs inside Claude Code with the same access Claude Code has, so read hooks/register.tsx before installing.

Settings

Each appears as a row in the Claude Code config menu under overalls; changing one reloads the mod. The /overalls command sets them from the prompt, which also works in the desktop app, where /config isn't available:

/overalls weather minimal
/overalls ponytail off
/overalls            (shows the current values)

The Config box open above the band: every choice for each setting in two columns, the current one ticked; below it the band, wrapped onto a second row

The ⚙ at the right of the band opens a Config box above it with every choice for every setting, the current one ticked; pressing one sets it, so you see the change in the band as you make it. Press ⚙ again to close it. Hover over a setting's name in the Config box for a line on what it is.

Pressing the forecast itself (Showers, or 67% at minimal) steps the weather detail through minimal → normal → full and round again; off is set in the Config box.

Where the mod has a /config row (the terminal), /overalls sets that row. Where it has none (the desktop app), it keeps the choice in the mod's own store instead, and that choice wins over the /config value in every session until you set the same setting with /overalls in a session that has the row.

| Setting | Values | Default | What it does | |---|---|---|---| | Weather detail | off · minimal · normal · full (typed; anything else counts as full) | full | How much of the forecast to show | | Ponytail level | off · icon · text (typed; anything else counts as icon, and an old on/off value as icon/off) | icon | Show whether Ponytail is installed and its level, after its logo or the word ponytail: | | Caveman mode | off · icon · text (typed; anything else counts as icon) | icon | Show Caveman's mode where it's installed, after 🪨 or the word caveman: | | Offer megacave | on · off | off | List Caveman's Classical Chinese mode (megacave) in its dropdown; in the Config box it sits on Caveman's row | | Usage limits | on · off | on | Show how much of your 5-hour and weekly limits is spent (subscriptions only) | | Limit resets | on · off | on | Show how long until each limit resets (5h 42% ↻1h20m); in the Config box it sits on the Limits row | | Limit run-out | off · warn · always (typed; anything else counts as warn) | warn | Warn when a limit will run out before it resets, at your pace over the last hour: ⚠1h40m in amber, red under 30 minutes. always also shows ✓ lasts for a limit that won't. Needs 10 minutes of samples and 2 points of movement first. Follows each limit, or stands alone (5h ⚠1h40m) with the limits off | | Session cost | on · off | off | Show what this session has cost so far | | MCP warnings | on · off | on | Warn when an MCP server or connector fails or needs signing in again | | Running agents | on · off | on | Show ⧗ 2 agents while subagents run; pressing it lists them (type and task) | | Turns left | on · off | on | Show ⌛ ~6 turns: about how many more turns fit, at the average growth of the last five that grew (red from 3) | | Tool denials | on · off | on | Show ⛔ 2 denied for tool calls refused by you, a hook, a permission rule or the auto-mode classifier; pressing it lists them, with Dismiss |

What each weather level shows:

| Level | Band | |---|---| | minimal | ☂ 67% | | normal | ☂ Showers 67% · 134.4k / 200k | | full | normal plus the last 12 turns as a sparkline and the change since last turn | | off | nothing (the Ponytail segment still shows if enabled) |

Ponytail detection

<picture> <source media="(prefers-color-scheme: dark)" srcset="assets/ponytail-logo-dark.png"> <img src="assets/ponytail-logo.png" width="110" alt="Ponytail, the lazy senior dev"> </picture>
  • Installed: an enabled ponytail@… entry in enabledPlugins. Otherwise the band shows not installed beside the logo.
  • Level: this session's own. Ponytail keeps a single level file for every session, so it can't say what this session runs at; Overalls tracks it per session instead, by Ponytail's rules:
    • a new session, and a compaction (Ponytail activates afresh), start at Ponytail's default: $PONYTAIL_DEFAULT_MODE, else defaultMode in its config.json ($XDG_CONFIG_HOME/ponytail/, or ~/.config/ponytail/), else full
    • /ponytail <level> (or /ponytail:ponytail <level>), /ponytail-review, stop ponytail and normal mode change it as they go in. Another session's switch doesn't change this band.
  • Switched by picking a level from the dropdown the level is drawn as (on mobile, which has no dropdown, a press steps ultra → full → lite → off), through Ponytail's own /ponytail <level> command.

Installing Ponytail or Caveman

Where either isn't installed, its row in the ⚙ Config box has an Install button. A mod can't install plugins, so it types a request into the prompt box, for example:

Install the caveman Claude Code plugin: run `claude plugin marketplace add JuliusBrussee/caveman` then `claude plugin install caveman@caveman`.

Send it and Claude runs the two commands, each behind the usual permission prompt. A plugin's hooks start with the next session.

Caveman

  • Installed: an enabled caveman@… entry in enabledPlugins; otherwise nothing shows.
  • Mode: this session's own. Caveman keeps each session's mode in .caveman-sessions/<session id>.mode in your Claude config directory, so the band reads that. A session with no file of its own (one started before Caveman was installed) shows off; the shared .caveman-active, which holds the last mode set in any window, is read only when there's no session id.
  • Switched by picking a mode from its dropdown (ultracave, caveman, off, and megacave when Offer megacave is on, since it answers in Classical Chinese; on mobile a press steps through them), through Caveman's own /megacave, /ultracave, /caveman and /caveman off commands.

MCP warnings

Claude Code gives a mod no list of MCP servers or their state, so the band learns of trouble from Claude's own tool calls:

  • an mcp__<server>__… call that fails to sign in or connect (a bad-arguments error doesn't count), and
  • the servers a ToolSearch reports as failed.

The band then shows ⚠ 2 MCP errors. Pressing it opens an MCP errors box above the band (like the Config box; one is open at a time) with a row per server: its name, sign in or failed, the error as Claude saw it, and:

  • Reconnect: for a claude.ai connector, Customize → Connectors, opened in the desktop app itself there (claude://claude.ai/customize/connectors), and at https://claude.ai/customize/connectors from the CLI or the web. For any other server, /mcp in the terminal; the desktop app's /mcp only lists servers, so there it says to sign in from a terminal session.
  • Dismiss, and Dismiss all

A server leaves the list on its next successful call, or when dismissed. It's caught on its first failure, not before.

Data and access

Overalls makes no network requests and sends nothing anywhere. Everything it does stays inside your Claude Code session:

  • reads the session's context-window usage ($.session.usage()) after each turn
  • reads your Claude Code settings to see whether Ponytail is enabled
  • reads the session's usage-limit percentages, reset times and cost ($.session.usage()) when those widgets are on, and the clock to count down to each reset
  • reads the session's list of subagents ($.agent.list(): type, task, status) when the agents widget is on
  • redraws the band every 30 seconds, so countdowns and the agent count stay current, and at each redraw notes the usage-limit percentages ($.session.usage()), keeping the last hour of them in session memory to tell when a limit will run out
  • reads your Claude Code settings to see whether Caveman is enabled and, if it is, this session's id and Caveman's mode file for it in your Claude config directory: .caveman-sessions/<session id>.mode (or .caveman-active when there's no session id)
  • reads Ponytail's config.json, for its default level, and the PONYTAIL_DEFAULT_MODE, XDG_CONFIG_HOME, CLAUDE_CONFIG_DIR and HOME environment variables
  • reads each prompt you submit only to spot a Ponytail command (/ponytail …, stop ponytail, normal mode), keeping nothing of it but the level
  • keeps the last 12 readings and the Ponytail level in session state, which is gone when the session ends
  • switches Ponytail's level or Caveman's mode only when you pick one from the band: it runs /ponytail <level>, or Caveman's command for the mode, as if you had typed it (which Claude reads, as it would your typing), or types it into the prompt box if it can't run it
  • types an install request into the prompt box only when you press Install in the Config box; nothing is installed unless you send it and approve Claude's commands
  • reads the name of each tool Claude calls and, when one is refused (by you, a hook, a permission rule or the auto-mode classifier), keeps the tool's name and the first 100 characters of the reason in session state until you dismiss it
  • reads the name of each MCP tool Claude calls, the error text when one fails, and the failed-server list a ToolSearch returns, keeping only each failing server's name, whether it needs signing in or failed, and the first 100 characters of its error; it runs /mcp only when you press Reconnect in the terminal
  • reads CLAUDE_CODE_ENTRYPOINT while the MCP errors box is open, to tell the desktop app from the CLI and the web; in the desktop app, pressing Reconnect on a connector hands claude://claude.ai/customize/connectors to the system's opener (open on macOS, xdg-open on Linux, cmd /c start on Windows), which opens that page in the app
  • compacts the conversation only when you press its Compact button; where Claude Code doesn't let a plugin compact (the desktop app), that press runs /compact for you, or types it into the prompt box if it can't run it
  • changes its own settings only when you run /overalls weather … or /overalls ponytail … (and the rest), pick one in the ⚙ Config box, or press the forecast to step the weather detail: through the /config row where there is one (saved in your Claude Code settings, as /config saves them), otherwise in the mod's own store, a small JSON file Claude Code keeps for the plugin in your Claude config directory.

Apart from that store, it writes no files, and the only program it starts is that system opener, with that one fixed address, when you press Reconnect.

It hooks four events only to observe them, never changing what they carry: tool.call (note an MCP server failing or answering again, and a refused call), turn.complete (take a reading), session.compact (record the drop after a compaction, and reset the Ponytail level to its default) and prompt.submit (note a Ponytail switch once your prompt has gone in, so /ponytail lite shows straight away). It also draws the band above the prompt.

Development

Load your clone directly instead of the installed copy, so saves hot-reload:

claude --plugin-dir ~/Projects/overalls

or for every session (including the desktop app), in ~/.claude/settings.json:

{ "env": { "CLAUDE_CODE_PLUGIN_DIRS": "~/Projects/overalls" } }

Don't also have the marketplace copy installed, or you'll get two bands.

claude plugin validate .
claude plugin test .

hooks/register.tsx is the module; types/index.d.ts declares the state it keeps. To add a setting, declare a field under userConfig in .claude-plugin/plugin.json and read it from options in register.

Licence

MIT

Credits

Ponytail and its logo are by Dietrich Gebert, used under the MIT licence (assets/PONYTAIL-LICENSE). Overalls only reads the level Ponytail writes; it isn't affiliated with or endorsed by the Ponytail project.

Caveman is by Julius Brussee; "Caveman" is his trademark. Overalls only reads the mode Caveman writes and runs its commands, uses none of its logos (🪨 is a stock emoji), and isn't affiliated with or endorsed by the Caveman project.

查看原始来源 ↗

更多类似作品