-
-
Notifications
You must be signed in to change notification settings - Fork 317
docs: update statusline documentation with cost source options #575
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Add comprehensive documentation for the new --cost-source option in statusline command: - Document all four cost source modes: auto, ccusage, cc, both - Add setup examples for settings.json configuration - Show output format differences for both mode - Explain when to use each mode with practical guidance - Update output format examples with both costs display References recent PRs: - feat(statusline): add costSource option to use Claude Code session cost (#571) - feat(statusline): add 'both' cost source option to display cc and ccusage costs (#574)
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
ccusage-guide | d781670 | Commit Preview URL Branch Preview URL |
Aug 22 2025, 11:34 AM |
|
Caution Review failedThe pull request is closed. WalkthroughDocumentation updates introduce Cost Source Options for the statusline, detailing modes (auto, ccusage, cc, both), CLI usage, Settings.json examples, and output examples. Components Explained now notes mode-dependent Session Cost. No code or API changes. Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Poem
Tip 🔌 Remote MCP (Model Context Protocol) integration is now available!Pro plan users can now connect to remote MCP servers from the Integrations page. Connect with popular remote MCPs such as Notion and Linear to add more context to your reviews and chats. 📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 💡 Knowledge Base configuration:
You can enable these sources in your CodeRabbit configuration. 📒 Files selected for processing (1)
✨ Finishing Touches🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. CodeRabbit Commands (Invoked using PR/Issue comments)Type Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Summary of Changes
Hello @ryoppippi, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!
This pull request updates the statusline documentation to incorporate the recently added cost source options. It provides comprehensive details on how to configure and interpret the new --cost-source parameter, ensuring users understand the different calculation modes and their implications for session cost display.
Highlights
- Cost Source Documentation: Comprehensive documentation for the new --cost-source parameter, detailing its available modes: auto, ccusage, cc, and both.
- Configuration Examples: Updated settings.json examples demonstrating how to configure the statusline to use different cost source modes.
- Output Format Examples: Enhanced examples showing the statusline output, specifically illustrating how the "both" mode displays both Claude Code and ccusage costs.
- Usage Guidance: Practical guidance on when to use each cost source mode, helping users choose the most appropriate option for their needs.
- Component Explanations: Updates to the "Session Cost" component explanation to reference the new cost source options, providing clarity on cost calculation methods.
Using Gemini Code Assist
The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.
Invoking Gemini
You can request assistance from Gemini at any point in your pull request via creating an issue comment (i.e. comment on the pull request page) using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands.
| Feature | Command | Description |
|---|---|---|
| Code Review | /gemini review |
Performs a code review for the current pull request in its current state. |
| Pull Request Summary | /gemini summary |
Provides a summary of the current pull request in its current state. |
| Comment | @gemini-code-assist | Responds in comments when explicitly tagged, both in issue comments and review comments. |
| Help | /gemini help |
Displays a list of available commands. |
Customization
To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.
Limitations & Feedback
Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.
You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.
Footnotes
-
Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request does a great job of documenting the new --cost-source option for the statusline command. The new sections are well-structured and provide clear examples.
I have one suggestion to make the documentation even more helpful by clarifying the relationship between the new --cost-source option and the existing --mode option used by other commands.
Additionally, for completeness and better discoverability, consider updating docs/guide/cli-options.md to include the new --cost-source and --visual-burn-rate options in the statusline command section. This would ensure all command-line options are documented in the central reference file.
| - **`auto`**: Best for most users, provides accurate costs with fallback reliability | ||
| - **`ccusage`**: When you want consistent calculation methods across all ccusage commands | ||
| - **`cc`**: When you trust Claude Code's cost calculations and want minimal processing |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The descriptions for the cost source modes are good, but they could be more precise by explicitly linking them to the global --mode option used by other ccusage commands. This would improve clarity for users familiar with other commands and prevent potential confusion about how statusline's cost calculation relates to the rest of the tool.
| - **`auto`**: Best for most users, provides accurate costs with fallback reliability | |
| - **`ccusage`**: When you want consistent calculation methods across all ccusage commands | |
| - **`cc`**: When you trust Claude Code's cost calculations and want minimal processing | |
| - **`auto`**: Best for most users. It provides accurate costs by preferring Claude Code's data and falling back to `ccusage`'s calculation, similar to the default `--mode auto` behavior in other commands. | |
| - **`ccusage`**: Use this for a consistent calculation method across all `ccusage` commands, equivalent to using `--mode calculate` with commands like `daily` or `blocks`. | |
| - **`cc`**: Use this when you trust Claude Code's pre-calculated costs and want minimal processing, similar to the `--mode display` behavior in other commands. |
Summary
Updates the statusline documentation to reflect recent cost source feature additions in PRs #571 and #574.
Changes Made
--cost-sourceparametersettings.jsonCost Source Modes Documented
auto(default): Prefer Claude Code cost, fallback to ccusage calculationccusage: Always use ccusage token-based calculationcc: Always use Claude Code's pre-calculated costboth: Display both costs side by side for comparisonReferences
Test Plan
Summary by CodeRabbit