Skip to content

feat(statusline): ship Codex and agy statuslines, keep Claude sessions - #437

Open
ycpss91255 wants to merge 4 commits into
mainfrom
feat/436-codex-agy-statusline
Open

ycpss91255 wants to merge 4 commits into
mainfrom
feat/436-codex-agy-statusline

Conversation

@ycpss91255

Copy link
Copy Markdown
Owner

Summary

Ship the Codex and Antigravity CLI (agy) statuslines next to the existing Claude Code one, and stop Claude Code from deleting session transcripts. Closes #436.

Changes

  • module/codex-config.module.sh (new, Archetype D) + module/config/codex/status_line.toml:
    • Upserts status_line = ["model-with-reasoning", "context-used", "weekly-limit", "current-dir", "git-branch", "branch-changes"] under [tui] in ${CODEX_HOME:-~/.codex}/config.toml.
    • Touches only that line: other keys, sections and comments are kept (herdr's terminal_title lives in the same table). It creates the file or the [tui] table when missing, replaces a multi-line array value, keeps the file mode, and writes through a temp file.
    • remove / purge drop only the status_line line. is_outdated = the value differs from the template.
  • module/agy-config.module.sh (new, Archetype D) + module/config/agy/statusline.py:
    • Installs the renderer to ~/.gemini/antigravity-cli/statusline.py (755) and merges "statusLine": {"type": "command", "command": <abs path>} into settings.json with jq. Other keys are preserved; an empty file counts as {}; invalid JSON is left untouched and the install fails.
    • remove deletes the script and drops statusLine only when it still points at the managed script, so a user's own command stays.
    • The renderer reads agy's stdin payload (model.display_name, context_window.used_percentage, quota["gemini-weekly"], workspace.current_dir) and prints the same two rows as the ccstatusline layout. Missing or malformed fields are skipped.
  • module/config/claude/settings.json: cleanupPeriodDays: 36500.
  • doc/module/INDEX.md regenerated; CHANGELOG [Unreleased] entries under Added and Changed.

Decision

  • Both new modules are custom instead of config-drop: a whole-file drop would overwrite keys that other tooling writes into the same files.
  • agy gets its own renderer because ccstatusline only understands the Claude Code payload.
  • agy-config depends on jq and python3, not on an agy install module (none exists yet); is_recommended checks for agy on PATH.

Tests

  • just -f justfile.ci test-unit codex-config: 22/22
  • just -f justfile.ci test-unit agy-config: 22/22 (includes renderer output, git branch/changes, and malformed-input cases)
  • just -f justfile.ci test-unit claude-code-config: 104/104
  • just -f justfile.ci lint
  • Before this change, the same settings were applied on the maintainer's machine and checked live for all three agents in a herdr pane.

Add a custom-archetype module that sets only the status_line key under
[tui] in ~/.codex/config.toml, so keys written by other tooling (such as
herdr's terminal_title) are preserved.
Drop a statusline.py renderer into ~/.gemini/antigravity-cli and merge
only the statusLine key into its settings.json with jq. The renderer
prints the same two-row layout as the shipped ccstatusline config.
Set cleanupPeriodDays to 36500 so Claude Code no longer deletes
transcripts after the default 30 days.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(statusline): ship Codex and agy statuslines, keep Claude sessions

1 participant