Skip to content

armgit / codex

Public Imported from GitHub
0

Lightweight coding agent that runs in your terminal

Rust

Add vim-style navigation for CLI option selection (#7784)

Bryant Rolfe225a5f7ffb98
diff --git a/codex-rs/tui/src/bottom_pane/list_selection_view.rs b/codex-rs/tui/src/bottom_pane/list_selection_view.rs
index 26a32a42e1..d23fd8ed3b 100644
--- a/codex-rs/tui/src/bottom_pane/list_selection_view.rs
+++ b/codex-rs/tui/src/bottom_pane/list_selection_view.rs
@@ -284,6 +284,11 @@ impl BottomPaneView for ListSelectionView {
modifiers: KeyModifiers::NONE,
..
} /* ^P */ => self.move_up(),
+ KeyEvent {
+ code: KeyCode::Char('k'),
+ modifiers: KeyModifiers::NONE,
+ ..
+ } if !self.is_searchable => self.move_up(),
KeyEvent {
code: KeyCode::Down,
..
@@ -298,6 +303,11 @@ impl BottomPaneView for ListSelectionView {
modifiers: KeyModifiers::NONE,
..
} /* ^N */ => self.move_down(),
+ KeyEvent {
+ code: KeyCode::Char('j'),
+ modifiers: KeyModifiers::NONE,
+ ..
+ } if !self.is_searchable => self.move_down(),
KeyEvent {
code: KeyCode::Backspace,
..