From fa56b0313356941e72a28abf255d25231aa81862 Mon Sep 17 00:00:00 2001 From: Henrik Friedrichsen Date: Sun, 10 Mar 2019 21:27:25 +0100 Subject: [PATCH] attempt to reconstruct search term --- src/commands.rs | 1 - src/main.rs | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/commands.rs b/src/commands.rs index fa0cfcc..e6c1a69 100644 --- a/src/commands.rs +++ b/src/commands.rs @@ -37,7 +37,6 @@ impl CommandManager { } pub fn handle(&self, s: &mut Cursive, cmd: String) -> Result, String> { - // TODO: handle quoted arguments let components: Vec = cmd.split(' ').map(|s| s.to_string()).collect(); if let Some(cb) = self.commands.get(&self.handle_aliases(&components[0])) { diff --git a/src/main.rs b/src/main.rs index f1c41f0..66e88c4 100644 --- a/src/main.rs +++ b/src/main.rs @@ -227,7 +227,7 @@ fn main() { }); if args.len() >= 1 { s.call_on_id("search_edit", |v: &mut EditView| { - v.set_content(args[0].clone()); + v.set_content(args.join(" ")); }); } Ok(None)