notedeck

One damus client to rule them all
git clone git://jb55.com/notedeck
Log | Files | Refs | README | LICENSE

commit b2b14fb6c7b3116e7ab3222e7f72204215f8f8ad
parent c6a96d8dbfef399d29ca1ce9106ce685b4157911
Author: William Casarin <jb55@jb55.com>
Date:   Fri, 30 Jan 2026 11:43:06 -0800

feat(dave): add Ctrl+Shift+T to clone agent with same working directory

Adds a new keybinding that creates a new agent session with the same
working directory as the currently selected agent, useful for spawning
parallel tasks in the same project.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

Diffstat:
Mcrates/notedeck_dave/src/lib.rs | 18++++++++++++++----
Mcrates/notedeck_dave/src/ui/keybindings.rs | 7+++++++
2 files changed, 21 insertions(+), 4 deletions(-)

diff --git a/crates/notedeck_dave/src/lib.rs b/crates/notedeck_dave/src/lib.rs @@ -477,13 +477,13 @@ You are an AI agent for the nostr protocol called Dave, created by Damus. nostr ui.separator(); if ui .button("List View") - .on_hover_text("Ctrl+G to toggle views") + .on_hover_text("Ctrl+L to toggle views") .clicked() { self.show_scene = false; } if ctrl_held { - ui::keybind_hint(ui, "G"); + ui::keybind_hint(ui, "L"); } }); ui.separator(); @@ -610,13 +610,13 @@ You are an AI agent for the nostr protocol called Dave, created by Damus. nostr ui.horizontal(|ui| { if ui .button("Scene View") - .on_hover_text("Ctrl+G to toggle views") + .on_hover_text("Ctrl+L to toggle views") .clicked() { self.show_scene = true; } if ctrl_held { - ui::keybind_hint(ui, "G"); + ui::keybind_hint(ui, "L"); } }); ui.separator(); @@ -754,6 +754,13 @@ You are an AI agent for the nostr protocol called Dave, created by Damus. nostr } } + /// Clone the active agent, creating a new session with the same working directory + fn clone_active_agent(&mut self) { + if let Some(cwd) = self.session_manager.get_active().map(|s| s.cwd.clone()) { + self.create_session_with_cwd(cwd); + } + } + /// Delete a session and clean up backend resources fn delete_session(&mut self, id: SessionId) { // Remove from focus queue first @@ -1511,6 +1518,9 @@ impl notedeck::App for Dave { KeyAction::NewAgent => { self.handle_new_chat(); } + KeyAction::CloneAgent => { + self.clone_active_agent(); + } KeyAction::Interrupt => { self.handle_interrupt_request(ui); } diff --git a/crates/notedeck_dave/src/ui/keybindings.rs b/crates/notedeck_dave/src/ui/keybindings.rs @@ -39,6 +39,8 @@ pub enum KeyAction { ToggleAutoSteal, /// Open external editor for composing input (Ctrl+G) OpenExternalEditor, + /// Clone the active agent with the same working directory (Ctrl+Shift+T) + CloneAgent, } /// Check for keybinding actions. @@ -89,6 +91,11 @@ pub fn check_keybindings( return Some(KeyAction::FocusQueueNext); } + // Ctrl+Shift+T to clone the active agent (check before Ctrl+T) + if ctx.input(|i| i.modifiers.matches_exact(ctrl_shift) && i.key_pressed(Key::T)) { + return Some(KeyAction::CloneAgent); + } + // Ctrl+T to spawn a new agent if ctx.input(|i| i.modifiers.matches_exact(ctrl) && i.key_pressed(Key::T)) { return Some(KeyAction::NewAgent);