feat(interactive): add an interactive mode for repos#30
Merged
Conversation
There was a problem hiding this comment.
Pull Request Overview
Adds a fully interactive terminal UI for repository scanning and Git operations, updates status coloring to support both table and TUI modes, and adjusts CLI flags and dependencies to enable the new feature.
- Introduces a
--interactiveflag and theInteractiveModemodule built with crossterm and ratatui. - Refactors status coloring by renaming
colortocomfy_color, addingratatui_color, and updating all consumers. - Adjusts CLI short options (
-s,-n) and updates snapshots; adds new dependencies (crossterm,ratatui, andcastaway).
Reviewed Changes
Copilot reviewed 11 out of 12 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| typos.toml | Added “ratatui” to the typo correction list. |
| src/cli.rs | Added interactive flag, rebased short options for summary, subdir, and non_clean. |
| src/main.rs | Imported and invoked InteractiveMode when --interactive is set. |
| src/gitinfo/status.rs | Renamed color to comfy_color, introduced ratatui_color. |
| src/printer.rs | Updated status cells to use comfy_color. |
| src/tests/snapshots/.../git-statuses.snap | Updated snapshots for new short flags and interactive option. |
| src/interactive/* | New interactive mode implementation and UI rendering code. |
| Cargo.toml | Added dependencies for crossterm, ratatui, and castaway. |
Comments suppressed due to low confidence (3)
src/cli.rs:55
- No tests validate the new interactive mode flag. Consider adding an integration or unit test to ensure
--interactivecorrectly enters interactive mode and that fallback behavior remains unchanged.
pub interactive: bool,
src/gitinfo/status.rs:123
- [nitpick] The newly added
ratatui_colormethod lacks a doc comment. Adding a brief description of its mapping from status variants to TUI colors would improve code clarity.
pub const fn ratatui_color(&self) -> ratatui::style::Color {
Cargo.toml:29
- The
castawaydependency is not referenced anywhere in the codebase. If it's not required for interactive mode or other features, consider removing it to reduce dependency bloat.
castaway = "0.2.4"
5f544bf to
12d48e4
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.