Add CLI components and supporting logic - #5
Conversation
BREAKING CHANGE: `nullforge cast -i <inventory>` replaces `pyinfra <inventory> nullforge/foundry/full_cast.py` invocation.
|
Warning Review limit reached
Next review available in: 44 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (28)
📝 WalkthroughWalkthroughThis PR adds a Click-based ChangesCLI framework and application wiring
Cast command and Pyinfra pipeline
Completion and rune-listing commands
Estimated code review effort: 4 (Complex) | ~45 minutes Sequence Diagram(s)sequenceDiagram
participant CLI
participant FoundryController
participant PyinfraWrapper
participant cast_selected
CLI->>FoundryController: cast inventory, runes, and options
FoundryController->>PyinfraWrapper: execute assembled Pyinfra command
PyinfraWrapper->>cast_selected: run selective cast module
cast_selected->>cast_selected: validate and include selected runes
Possibly related PRs
Suggested labels: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ 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 |
There was a problem hiding this comment.
Actionable comments posted: 3
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@nullforge/cli/components/completion/powershell.py`:
- Around line 73-74: Update format_completion to normalize carriage-return and
newline characters in item.help before constructing the tab-separated PowerShell
completion record. Preserve the existing empty-help fallback and replace
multiline breaks with a single-line representation so each completion remains
one record.
- Around line 25-29: Update the completion branch to handle "file" and "dir"
types separately. Keep the "file" path using Get-ChildItem with the existing
ProviderItem completion metadata, and make the "dir" path use Get-ChildItem with
the -Directory filter and ProviderContainer result type so only directories are
suggested as native containers.
In `@README.md`:
- Around line 8-35: Update every documented nullforge CLI invocation in the
README CLI section to run through the uv project environment, using the uv run
prefix so the examples work immediately after uv sync without requiring shell
activation.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: 4458dbd9-cd06-44c0-8e59-e7b84b827f19
📒 Files selected for processing (28)
README.mdnullforge/cli/__init__.pynullforge/cli/__main__.pynullforge/cli/app.pynullforge/cli/components/__init__.pynullforge/cli/components/completion/__init__.pynullforge/cli/components/completion/component.pynullforge/cli/components/completion/controller.pynullforge/cli/components/completion/errors.pynullforge/cli/components/completion/powershell.pynullforge/cli/components/foundry/__init__.pynullforge/cli/components/foundry/component.pynullforge/cli/components/foundry/controller.pynullforge/cli/components/foundry/errors.pynullforge/cli/components/runes/__init__.pynullforge/cli/components/runes/component.pynullforge/cli/components/runes/controller.pynullforge/cli/core/__init__.pynullforge/cli/core/application.pynullforge/cli/core/component.pynullforge/cli/core/controller.pynullforge/cli/core/errors.pynullforge/cli/core/types.pynullforge/cli/display.pynullforge/cli/types.pynullforge/foundry/_pyinfra.pynullforge/foundry/cast.pypyproject.toml
Type of change
Description
Why is this change needed?
To improve UX with running runes
Related Issues
Testing
uv run poe tests)Checklist
uv run poe check)Summary by CodeRabbit
nullforgecommand-line interface for casting all features or selected runes.nullforgecommand installation and improved command output labeling.