Repository navigation
feat: ni (パッケージマネージャー自動選択ツール) を導入 - #82
Conversation
- @antfu/ni を devDependencies に追加 - CLAUDE.md に ni コマンド対応表と推奨コマンド例を追加 - カバレッジ計測セクションを ni コマンドに更新 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
WalkthroughThe changes introduce the ni package manager auto-selector tool to the project by documenting its command-mapping workflow in CLAUDE.md and adding the ni package along with vitest coverage support to devDependencies in package.json. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes
Possibly related PRs
Poem
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
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. Comment |
コードレビュー✅ 良い点
🔍 改善提案1. README.md の一貫性 (重要度: 中)README.md に 現状: npm run dev推奨: # ni を使用(推奨)
nr dev
# または直接実行
bun run dev2. package.json のスクリプトとの整合性 (重要度: 低)package.json では以下のように npm コマンドを使用しています。 "dev:control-plane": "npm run dev --workspace=frontend/control-plane",
"dev:admin": "npm run dev --workspace=frontend/admin-app",
"dev:participant": "npm run dev --workspace=frontend/participant-app",
"build:frontend": "npm run build --workspaces --if-present",ni は workspace コマンドもサポートしているため、将来的にこれらも統一できる可能性があります(ただし、現時点では変更不要)。 3. @vitest/coverage-v8 の追加理由 (重要度: 低)
📋 チェック項目
🎯 推奨アクション
総合評価LGTM with minor suggestions 🎉 ni の導入により開発者体験が大幅に向上します。上記の軽微な改善提案を対応いただければ、すぐにマージ可能です。 🤖 Generated with Claude Code |
There was a problem hiding this comment.
Actionable comments posted: 2
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
bun.lockbis excluded by!**/bun.lockb
📒 Files selected for processing (2)
CLAUDE.md(2 hunks)package.json(1 hunks)
🧰 Additional context used
📓 Path-based instructions (1)
**/*.md
📄 CodeRabbit inference engine (CLAUDE.md)
**/*.md: 文末は「」で終わる。コロンや記号で文を終わらせない。日本語と半角英数字の間には半角スペースを入れる
技術用語・記号は原語を保ちつつ、日本語文脈に合わせて表記ゆれをなくす。例: 100% と表記する
Files:
CLAUDE.md
🧠 Learnings (3)
📚 Learning: 2025-11-24T23:43:51.686Z
Learnt from: CR
Repo: susumutomita/TenkaCloud PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-11-24T23:43:51.686Z
Learning: Refer to CLAUDE.md for coding standards and guidelines
Applied to files:
CLAUDE.md
📚 Learning: 2025-11-29T14:55:50.084Z
Learnt from: CR
Repo: susumutomita/TenkaCloud PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-29T14:55:50.084Z
Learning: Applies to **/*.{test,spec}.{ts,tsx} : すべてのコードパスを含めてテストカバレッジ 100% を達成する
Applied to files:
CLAUDE.md
📚 Learning: 2025-11-29T14:55:50.084Z
Learnt from: CR
Repo: susumutomita/TenkaCloud PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-29T14:55:50.084Z
Learning: Applies to **/*.{test,spec}.{ts,tsx} : テスト駆動開発 (TDD) を実践する。コードを書く前に失敗するテストを書く
Applied to files:
CLAUDE.md
🔇 Additional comments (5)
package.json (1)
41-41: @vitest/coverage-v8 version is current.The pinned version (^4.0.14) matches the latest published release, which supports the coverage measurement updates in CLAUDE.md.
CLAUDE.md (4)
758-764: Coverage commands properly updated to use ni.The coverage section appropriately transitions to ni commands (
nr test:coverage) with a fallback to direct bun commands. This aligns well with the package.json changes introducing @vitest/coverage-v8.
878-880: Comprehensive ni documentation section added.The new section provides clear positioning of ni in the project workflow, with a link to the upstream package and well-structured command reference. The introduction clearly states the rationale for ni adoption.
882-894: Command mapping table is comprehensive and accurate.The table covers all essential ni commands with clear bun equivalents. Mapping aligns with ni's behavior of detecting lock files (including bun.lockb) and running corresponding commands.
897-915: Usage examples are clear and practical.The recommended commands cover the essential workflows (install, dev, test, coverage, build, typecheck). Examples follow the concise format used elsewhere in CLAUDE.md.
| - lock ファイル(bun.lockb)を検出して自動的に bun を使用する | ||
| - 新規参加者が「npm i in a bun project」のような間違いを防げる | ||
| - CI/CD やドキュメントでパッケージマネージャーを統一できる |
There was a problem hiding this comment.
Add periods to bullet points to comply with documentation guidelines.
Per the coding guidelines, sentences should end with proper punctuation. The advantage bullet points currently end with verb forms (〜できる/〜する) rather than 「。」markers. Restructure these as complete sentences or add periods.
### 利点
- lock ファイル(bun.lockb)を検出して自動的に bun を使用する
- - 新規参加者が「npm i in a bun project」のような間違いを防げる
- - CI/CD やドキュメントでパッケージマネージャーを統一できる
+ - lock ファイル(bun.lockb)を検出して自動的に bun を使用する。
+ - 新規参加者が「npm i in a bun project」のような間違いを防げる。
+ - CI/CD やドキュメントでパッケージマネージャーを統一できる。Committable suggestion skipped: line range outside the PR's diff.
🤖 Prompt for AI Agents
In CLAUDE.md around lines 918 to 920, the three bullet points lack terminal
punctuation; update each bullet to be a complete sentence by appending the
Japanese full stop "。" (or rephrase to a complete sentence) so they end with
"。", ensuring consistency with documentation guidelines.
| }, | ||
| "devDependencies": { | ||
| "@types/bun": "latest" | ||
| "@antfu/ni": "^27.0.1", |
There was a problem hiding this comment.
Update @antfu/ni to the actual latest version (27.0.0).
The latest published version of @antfu/ni is 27.0.0, but the PR pins ^27.0.1, which doesn't exist yet. This can cause dependency resolution issues and breaks reproducibility. Update to "@antfu/ni": "^27.0.0" instead.
- "@antfu/ni": "^27.0.1",
+ "@antfu/ni": "^27.0.0",📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| "@antfu/ni": "^27.0.1", | |
| "@antfu/ni": "^27.0.0", |
🤖 Prompt for AI Agents
In package.json around line 39, the dependency pins "@antfu/ni": "^27.0.1" which
does not exist; update the version string to the actual published version by
changing it to "@antfu/ni": "^27.0.0" to avoid dependency resolution failures
and ensure reproducible installs.
概要
@antfu/ni を導入し、パッケージマネージャーに依存しないコマンド体系を確立する。
Closes #81
変更内容
@antfu/niを devDependencies に追加ni コマンド対応表
nibun installnr devbun run devnlx vitestbunx vitestncibun install --frozen-lockfile利点
テスト計画
🤖 Generated with Claude Code
Summary by CodeRabbit
Documentation
Chores
✏️ Tip: You can customize this high-level summary in your review settings.