You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat: add today and this-week shortcut commands #1300
ccusage today — shows all-agent daily usage for today only
ccusage this-week — shows all-agent daily usage since Monday of the current week
Why?
Checking today's or this week's usage currently requires manually calculating dates and passing --since/--until. These two shortcuts eliminate that friction for the most common quick-check scenarios.
This issue was auto-closed. Issues from new contributors are auto-closed by default.
Maintainers review auto-closed issues and reopen worthwhile ones. Issues that do not meet the quality bar in CONTRIBUTING.md may not be reopened or receive a reply.
Keep the issue short, concrete, and written in your own voice.
If a maintainer replies lgtmi, your future issues will stay open. If a maintainer replies lgtm, your future issues and PRs will stay open.
we had weekly, but actually today command sound really good lol
Thanks for the recognition! Like "today", "this-week" is basically just a shortcut for something people do often — it'd be great to also add a "this-month" option.
I opened #1321 with an implementation for the today and this-week shortcuts.
Adding a bit more context: I also need this for my own workflow. My company tracks weekly token usage, so having a direct ccusage this-week shortcut makes the reporting flow much simpler than calculating dates manually each time.
Happy to defer if @lushi516 is already working on an implementation. I already had a tested local version and wanted to share it for review.
I agree this-week overlaps with the existing weekly command, and using jq for the latest weekly row keeps the command surface smaller.
today still feels like a useful shortcut to me because it maps to a common single-day quick check, but I’m happy to narrow the PR to today only if that fits the project direction better.
Excuse me. I have an alternative idea to the one I proposed earlier.
I'd like to propose adding a -l, --last parameter to the daily, weekly, and monthly commands to output statistics for the most recent N units:
ccusage daily --last 1 # today
ccusage weekly --last 1 # this week
ccusage monthly --last 1 # this month
This keeps the existing style consistent while making it easy to view today / this week / this month. Since all three commands share the same time-filtering logic and only differ in granularity (day / week / month), the parameter maps naturally to each command's unit, so the implementation stays clean and unified.
@ryoppippi@jsiu93
Historical audit: this discussion was auto-closed by the legacy contributor gate. That closure did not assess technical importance.
Audit result: resolved. A later merged change or the current main implementation covers this request. This item is kept for history and does not need to be reopened.
Activity
pullfrog commentedon Jun 12, 2026
github-actions commentedon Jun 12, 2026
This issue was auto-closed. Issues from new contributors are auto-closed by default.
Maintainers review auto-closed issues and reopen worthwhile ones. Issues that do not meet the quality bar in CONTRIBUTING.md may not be reopened or receive a reply.
Keep the issue short, concrete, and written in your own voice.
If a maintainer replies
lgtmi, your future issues will stay open. If a maintainer replieslgtm, your future issues and PRs will stay open.See CONTRIBUTING.md.
ryoppippi commentedon Jun 14, 2026
we had weekly, but actually
todaycommand sound really good lolzengzuo613 commentedon Jun 14, 2026
Thanks for the recognition! Like "today", "this-week" is basically just a shortcut for something people do often — it'd be great to also add a "this-month" option.
jsiu93 commentedon Jun 15, 2026
I opened #1321 with an implementation for the
todayandthis-weekshortcuts.Adding a bit more context: I also need this for my own workflow. My company tracks weekly token usage, so having a direct
ccusage this-weekshortcut makes the reporting flow much simpler than calculating dates manually each time.Happy to defer if @lushi516 is already working on an implementation. I already had a tested local version and wanted to share it for review.
ryoppippi commentedon Jun 15, 2026
for week, why not jq?
ryoppippi commentedon Jun 15, 2026
we just want to keep ccusage as minimal as possible.
today does make sense, for week, just use jq to get that last row from
ccusage weekly?jsiu93 commentedon Jun 16, 2026
That makes sense, thanks for clarifying.
I agree
this-weekoverlaps with the existingweeklycommand, and usingjqfor the latest weekly row keeps the command surface smaller.todaystill feels like a useful shortcut to me because it maps to a common single-day quick check, but I’m happy to narrow the PR totodayonly if that fits the project direction better.zengzuo613 commentedon Jun 17, 2026
Excuse me. I have an alternative idea to the one I proposed earlier.
I'd like to propose adding a
-l, --lastparameter to thedaily,weekly, andmonthlycommands to output statistics for the most recent N units:
This keeps the existing style consistent while making it easy to view today / this week / this month. Since all three commands share the same time-filtering logic and only differ in granularity (day / week / month), the parameter maps naturally to each command's unit, so the implementation stays clean and unified.
@ryoppippi @jsiu93
ryoppippi commentedon Aug 31, 2026
Historical audit: this discussion was auto-closed by the legacy contributor gate. That closure did not assess technical importance.
Audit result: resolved. A later merged change or the current
mainimplementation covers this request. This item is kept for history and does not need to be reopened.