with one click
development
Guides ccusage monorepo development. Use when editing packages, docs, shared configuration, bundled CLI packaging, dependencies, exports, or validation commands.
Menu
Guides ccusage monorepo development. Use when editing packages, docs, shared configuration, bundled CLI packaging, dependencies, exports, or validation commands.
| name | development |
| description | Guides ccusage monorepo development. Use when editing packages, docs, shared configuration, bundled CLI packaging, dependencies, exports, or validation commands. |
This is a monorepo. Check the nearest package-specific AGENTS.md before editing a package:
apps/ccusage/AGENTS.md - main Claude Code usage CLI and librarydocs/AGENTS.md - VitePress documentation siteThe production CLI implementation is Rust-first under rust/crates/ccusage.
The apps/ccusage package now mainly provides npm metadata, a TypeScript bin
launcher, generated schema artifacts, benchmarks, and release packaging.
The canonical user-facing command is ccusage with agent subcommands:
ccusage daily
ccusage codex daily
ccusage opencode daily
ccusage amp daily
ccusage pi daily
Standalone agent wrapper packages have been removed. Prefer ccusage <agent> ... in docs, tests, examples, and new behavior, and do not reintroduce wrapper commands such as ccusage-codex, ccusage-opencode, ccusage-amp, or ccusage-pi.
Agent implementations live in the Rust CLI unless the work is specifically about
the remaining TypeScript package surface. Treat package runtime libraries as
bundled assets: add dependencies to each package's devDependencies unless the
user explicitly asks otherwise.
Use root commands unless a narrower package command is more appropriate. Read references/commands.md for root and main CLI command examples.
LOG_LEVEL controls logging verbosity from 0 silent through 5 trace.
Read references/environment-and-validation.md for direnv, tool management,
generated skill target rules, and post-change checks.
rust skill before editing rust/crates/**,
native packaging behavior, or Rust pricing embedding. Use
profile for Rust performance work.pub(crate) over
broader visibility, avoid unnecessary String cloning in hot paths, and put
unit tests beside the module they exercise.typescript skill before
editing. Keep satisfies and as const satisfies guidance there instead of
mixing TypeScript details into Rust workflow rules.devDependencies for bundled/private packages.Read references/environment-and-validation.md for formatting, typecheck, and
test commands.
Use profile for native CLI performance optimization, Rust profiling,
hyperfine A/B comparisons, branch-vs-main profiling, TypeScript launchers,
benchmarks, and packaging scripts.
Use the cmux-debug skill when validating terminal rendering, responsive tables, long-running CLI output, or output that depends on real terminal geometry.
Use the commit skill for commit structure, Conventional Commits, scope selection, and detailed commit message requirements.
Use the create-pr skill after opening a PR or pushing follow-up commits so AI and human review comments are requested, inspected, answered, and incorporated through small revertible commits.
Runs the full PR lifecycle. Use when creating a branch, committing, pushing, opening a PR, requesting AI review, and driving CI and review to completion.
Guides repo-local skill creation and updates. Use when adding or editing .agents/skills, SKILL.md frontmatter, references, scripts, or skill routing.
Guides ccusage Rust and Vitest tests. Use when adding or fixing cargo tests, CLI snapshots, Claude model pricing, LiteLLM compatibility, Vitest tests, or fixture-backed tests.
Guides ccusage TypeScript and JavaScript work. Use before reading or editing .ts, .tsx, .js, or .jsx files, including package launchers, Vitest tests, Bun scripts, schemas, mocks, and typed fixtures.
Guides t-wada Red-Green-Refactor TDD. Use when implementing features, fixing bugs, or refactoring logic with strict test-first development.
Guides ccusage agent source formats. Use when checking agent log locations, raw record structure, token mappings, model names, precomputed costs, or source-specific CLI behavior.