ClaudeMods
☰
ZH-CN
● 0 人在线 · 浏览 0 次
赞助提交作品
GitHub 仓库 · 发布者 DJPalefaceSD

gas-gauge

提示符上方的燃油表:显示每个窗口中剩余多少 Claude 计划额度,以及何时补充。

DJPalefaceSD@DJPalefaceSD

DJPalefaceSD/rostech-mods/tree/main/plugins/gas-gauge

已翻译

关于这个 mod

一个 Claude Code 插件,在提示符上方显示燃油表,指出每个窗口还剩多少 Claude 计划额度以及何时补充。

显示条示例:⛽ 5-hour E ███ ½ █░░ F 71% @ 3:40 PM——像汽车燃油表一样读取,左侧是 E,右侧是 F,中间是 ½。超过半箱为绿色,超过五分之一为黄色,低于该值为红色。每个油箱占显示条一半。当油箱剩余低于 25% 时显示一次提示,低于 10% 时再显示一次。

命令:/gas 输出每个油箱;/gas hide 将数字移到状态行;/gas show 恢复显示条。

/config 中的 Tanks to show 设置选择显示哪些窗口:both(默认)、单独 5-hour 或单独 week。排除的油箱会在显示条、/gas、警告和状态行中全部消失。

数字来自 Claude Code 从每次响应中读取的内容,因此 Claude 至少回答一次后油表才会填充;没有计划窗口的 API key 会保持空白。显示条绘制在终端和 Claude 桌面应用的 Code 标签页中(尚未支持手机应用)。已在 Claude Code 2.1.288 测试。

安装

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

claude plugin marketplace add DJPalefaceSD/rostech-mods
claude plugin install gas-gauge
原文 / README

Gas Gauge

A fuel gauge above the prompt: how much of your Claude plan is left in each window, and when it refills.

⛽ 5-hour  E ███ ½ █░░ F  71%  @ 3:40 PM

Read it like a car: E on the left, F on the right, the ½ mark in the middle. Green above half a tank, yellow above a fifth, red below that.

Each gauge takes half the band. A toast fires once when a tank drops past 25% left, and again past 10%.

  • /gas prints every tank.
  • /gas hide moves the numbers to the status line. /gas show brings the band back.

The Tanks to show setting, in /config, picks which windows the gauge shows: both (the default), 5-hour alone, or week alone. A tank it leaves out is gone everywhere, from the band, /gas, the warnings and the status line.

The numbers are the ones Claude Code itself reads off each response, so the gauge fills after Claude has answered once. On an API key with no plan windows, it stays empty.

The band draws in the terminal and in the Code tab of the Claude desktop app. The phone app does not draw it yet.

Tested with Claude Code 2.1.288.

更多类似作品