Project-specific. Global rules in ~/.claude/rules/ still apply.
mainis protected. No direct pushes. Every change goes through a PR.- Branch name:
<type>/<slug>(feat/...,fix/...,docs/...). - Rebase-merge PRs (never squash) so every commit lands individually on
mainand appears in the release notes. Every commit must be a valid Conventional Commit, not just the PR title. - All
ci.ymljobs (rust, frontend, installer) must pass before merge.
release-please reads commits on main to bump versions and publish to crates.io. Format: <type>(<scope>)<!>: <description>.
| Type | Bump (pre-1.0) |
|---|---|
feat: |
minor |
fix: |
patch |
feat!: / BREAKING CHANGE: |
minor (becomes major after 1.0) |
chore, docs, refactor, test, ci, perf, style |
none |
"Bump" is version impact only — chore/deps still appear in the changelog under "Dependencies & Chores" (see changelog-sections in release-please-config.json); only docs/style/refactor/test/build/ci stay hidden.
Tags: vX.Y.Z. After merge, release-please opens a rolling release PR; merging it tags + triggers publish.yml (cargo publish).
Never hand-edit: Cargo.toml version, Cargo.lock, .release-please-manifest.json, frontend/package.json, frontend/package-lock.json, CHANGELOG.md. Release-please owns them.
Rust changes (src/, Cargo.*):
cargo fmt --all -- --check
cargo clippy --all-targets --locked -- -D warnings
cargo test --lockedFrontend changes (frontend/):
cd frontend && npm run build && npm test -- --runIf both stacks changed, run both blocks. If embedded assets changed, build the frontend first (rust-embed needs frontend/dist/).
When you change MemoryMetrics/GpuMetrics/CpuMetrics shape, serde names, display logic, or fields — update all of these in the same PR:
- Rust unit tests in
src/metrics/ - TS types in
frontend/src/types/metrics.ts - Formatters in
frontend/src/lib/format.ts - Vitest specs in
frontend/src/__tests__/ - Components in
frontend/src/components/
If one is genuinely N/A, say so in the commit.
No behavior change merges without test coverage in the same PR. Rust branches → #[cfg(test)]. Frontend components/formatters → Vitest. New API field → both sides.