diff options
| author | DanConwayDev <DanConwayDev@protonmail.com> | 2026-02-12 10:24:11 +0000 |
|---|---|---|
| committer | DanConwayDev <DanConwayDev@protonmail.com> | 2026-02-12 10:24:11 +0000 |
| commit | 116ab6757ef22779b913a5e1c5e289ba7f3daefb (patch) | |
| tree | 3418acd28e8e050f33bbf14aaf36eab4a6ed7cee /src/bin/ngit/main.rs | |
| parent | bc6be27ae6d1d2befe0027c19aba3f6cd2d22535 (diff) | |
feat: make ngit list non-interactive by default
- Add --status flag for filtering (default: open,draft)
- Add --json flag for JSON output
- Add optional <id> argument for showing proposal details
- Rename interactive logic to launch_interactive()
- Non-interactive mode outputs table format by default
- Use -i flag for interactive mode
Phase 3 of non-interactive ngit list implementation.
Diffstat (limited to 'src/bin/ngit/main.rs')
| -rw-r--r-- | src/bin/ngit/main.rs | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/bin/ngit/main.rs b/src/bin/ngit/main.rs index ab57f89..f405e94 100644 --- a/src/bin/ngit/main.rs +++ b/src/bin/ngit/main.rs | |||
| @@ -45,11 +45,8 @@ async fn main() { | |||
| 45 | } | 45 | } |
| 46 | }, | 46 | }, |
| 47 | Commands::Init(args) => sub_commands::init::launch(&cli, args).await, | 47 | Commands::Init(args) => sub_commands::init::launch(&cli, args).await, |
| 48 | Commands::List => { | 48 | Commands::List { status, json, id } => { |
| 49 | // list is inherently interactive - it presents menus for | 49 | sub_commands::list::launch(status.clone(), *json, id.clone()).await |
| 50 | // browsing and selecting proposals | ||
| 51 | std::env::set_var("NGIT_INTERACTIVE_MODE", "1"); | ||
| 52 | sub_commands::list::launch().await | ||
| 53 | } | 50 | } |
| 54 | Commands::Send(args) => sub_commands::send::launch(&cli, args, false).await, | 51 | Commands::Send(args) => sub_commands::send::launch(&cli, args, false).await, |
| 55 | Commands::Sync(args) => sub_commands::sync::launch(args).await, | 52 | Commands::Sync(args) => sub_commands::sync::launch(args).await, |