Repository navigation
feat(tuios): sidebarにAI使用量を表示し、prefix u・C-uをcopy mode入りにする - #445
Merged
Merged
Conversation
- tui usageでai-usageを並列に呼び、tmux sidebarと同じ書式・ペース色でusage欄に描く - prefix u / C-uをtmuxと同じくcopy modeへの入口にする。半ページ上への移動は続くC-uで行う
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
tmux の sidebar にあった AI 使用量(残り)を tuios の sidebar に出す。
prefix u/prefix C-uを tmux と同じく copy mode の入口にする。Changes
tui usageを追加。ai-usage(claude / codex / gemini / cursor / grok)を並列に呼び、tmux-agent-sidebar.shと同じ書式で描く。リミット消化ペースの色も同じ判定(sb_pace_colorを移植)。usageを追加(sessions,custom,agents、30秒ごとに更新)。session 一覧は標準の sessions 欄だけで、重複はしない。prefix u/prefix C-uをprefix_selection(copy mode)に変更。tmux は copy mode に入ると同時に半ページ上へ移動するが、TUIOS 0.10.1 は1つのキーに2つの操作を割り当てられず、copy mode へ外からキーも送れない。そのため、続けて押すCtrl+u(copy mode 内の半ページ上)で移動する。scrollback ブラウザーのキー割り当ては外した。Test plan
python3 scripts/test-tui.py(41件。usage の書式とペース色、早期・使い切り・未知の label)tmux-agent-sidebar.shのsb_pace_colorと8パターンで突き合わせ、すべて一致ai-usageでtui usageが約1.5秒で終わる(custom section の3秒制限内)prefix u/prefix C-uで copy mode に入り、続くCtrl+uで半ページずつ上がることを確認