Repository navigation
Releases: pemagic/ClaudeUsage
Releases · pemagic/ClaudeUsage
Release list
v1.1.8
Fix: Pace display sign error
- Fixed: Pace showing "Behind (−X%)" now correctly displays "Behind (X%)"
- The minus sign was logically incorrect — "Behind" already indicates under expected pace
- Fixed in both menu bar popup and desktop widget
v1.1.7
What's New
Sleep Mode: Show Cached Data
- Sleep mode now displays cached usage data with a sleep indicator banner, instead of just showing "Paused"
- Menu popup header shows "💤 Sleeping · Xm ago" so you know how stale the data is
- Desktop widgets (small & medium) also show cached data with a "Sleeping · Cached" indicator
Always Show Weekly Usage
- Weekly and Sonnet sections are now always visible, even when usage is 0%
- Previously these sections would be completely hidden when no weekly data was available
README Fixes
- Fixed incorrect claim that only Claude Max plan is supported — ClaudeUsage works with all paid plans (Pro, Team, Max, Enterprise)
- Fixed incorrect medium widget size (340×160, not 320×140)
- Removed inaccurate color palette description for widgets
v1.1.6
Fix: 休眠检测不触发问题
根本原因:每次 UsageFetcher 运行 claude(工作目录 /tmp/claudeusage-probe),Claude Code CLI 会在 ~/.claude/projects/-tmp-claudeusage-probe/ 写入日志。空闲检测扫描到这些日志误以为用户在活跃使用 Claude,导致 claudeGoneSince 计时器不断被重置,休眠永远触发不了。
修复:扫描日志时跳过 -tmp-claudeusage-probe 路径。
v1.1.5 — 关于信息
新增
- 关于信息:在 Settings 和 Quit 之间添加丝印风格的关于区域,显示版本号和 GitHub 地址,点击可直接打开项目页面
包含 v1.1.4 修复
- 空闲检测误判修复(双重校验:pgrep + 日志时间戳)
v1.1.4 — 空闲检测误判修复
修复
- 空闲检测误判:修复了 ClaudeUsage 自身刷新时启动的 claude 进程被 pgrep 误检测为"用户正在使用 Claude",导致自动休眠永远无法激活的问题
改动
isClaudeRunning()→isClaudeActive():双重校验机制- 条件 1:pgrep 检测到 claude 进程存在
- 条件 2:
~/.claude/projects/下有 5 分钟内修改的 JSONL 日志文件
- 由于 fetcher 工作目录为
/tmp/claudeusage-probe,其日志不会写入~/.claude/projects/,因此不会干扰空闲检测
v1.1.3 — 空闲检测防抖修复
修复
- 空闲检测防抖:之前
pgrep偶尔一次未检测到 Claude 进程会立即暂停→恢复,造成闪烁 - 现在使用
claudeGoneSince时间戳,等够阈值时间才暂停,与用户空闲检测行为一致
下载
直接下载 ClaudeUsage.dmg,拖入应用程序文件夹即可。
v1.1.2 — Claude 进程检测 + 自动休眠
新功能
- 每 15 秒检测 Claude 进程是否在运行
- Claude 未运行时自动休眠(⏸),不再发起无意义的刷新
- Claude 重新启动 + 用户活跃时自动唤醒并刷新
修复(v1.1.1)
- 桌面小组件不再遮挡前端窗口
下载
直接下载 ClaudeUsage.dmg,拖入应用程序文件夹即可。
v1.1.1 — 小组件层级修复
修复
- 桌面小组件不再遮挡前端窗口,改为桌面图标层级(始终在所有窗口后面)
下载
直接下载 ClaudeUsage.dmg,拖入应用程序文件夹即可。
v1.1.0 - 桌面小组件 & 稳定性提升
新功能
- 桌面小组件 — 毛玻璃悬浮窗,Small (180×190) / Medium (340×160) 两种尺寸
- 跟随系统亮色/暗色自动适配
- 可拖拽到任意位置,重启后自动记住
- 跨所有桌面空间可见
- Settings → Desktop Widget 开关
Bug 修复
- 修复选择小组件时闪退(
_NSWindowTransformAnimationuse-after-free) - 修复
/usage频繁超时(等待❯提示符而非 600ms 安静期) - 修复小组件需点击菜单栏才出现的问题
其他
- 项目首页默认显示中文文档
- 致敬 CodexBar,简化对比说明
📦 下载 ClaudeUsage.dmg,打开后拖入 Applications 即可。
v1.0.2 — 倒计时解析修复
Changes since v1.0.1
- 配额重置自动刷新: 配额窗口到期后 5 秒自动拉取最新数据,不再卡在旧百分比 + "Resetting..."
- ANSI 解析修复: 修复 CLI TUI 光标优化导致 "6am" 被误解析为 "6 minutes" 的问题(显示错误的 "Resets in 5m")
- 相对时间正则严格化: 数字与单位之间不再允许空格,防止乱码文本误匹配
- 乱码时间回退解析: 新增启发式解析器,识别 ANSI 剥离后的残缺时间格式
- Auto-refresh on quota reset: Fetches fresh data 5s after usage window expires, no more stale "11% + Resetting..."
- ANSI parsing fix: Fixed CLI TUI cursor optimization garbling "6am" → "6 m", which was misinterpreted as "6 minutes"
- Strict relative-time regex: No spaces allowed between number and unit, preventing garbled text false positives
- Garbled time fallback: New heuristic parser recovers hour from ANSI-mangled time strings