From b3e687943811fd48589d7030122c33c7e9867ec9 Mon Sep 17 00:00:00 2001 From: sigoden Date: Mon, 30 Oct 2023 10:36:08 +0800 Subject: feat: deprecate prompt, remove `--prompt` and `.prompt` (#176) --- src/repl/mod.rs | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) (limited to 'src/repl/mod.rs') diff --git a/src/repl/mod.rs b/src/repl/mod.rs index fadb81f..46d0cca 100644 --- a/src/repl/mod.rs +++ b/src/repl/mod.rs @@ -19,11 +19,10 @@ use lazy_static::lazy_static; use reedline::Signal; use std::rc::Rc; -pub const REPL_COMMANDS: [(&str, &str); 15] = [ +pub const REPL_COMMANDS: [(&str, &str); 14] = [ (".info", "Print system-wide information"), (".set", "Modify the configuration temporarily"), (".model", "Choose a model"), - (".prompt", "Add a GPT prompt"), (".role", "Select a role"), (".clear role", "Clear the currently selected role"), (".session", "Start a session"), @@ -134,14 +133,6 @@ impl Repl { handler.handle(ReplCmd::UpdateConfig(args.unwrap_or_default().to_string()))?; self.prompt.sync_config(); } - ".prompt" => { - let text = args.unwrap_or_default().to_string(); - if text.is_empty() { - print_now!("Usage: .prompt .\n\n"); - } else { - handler.handle(ReplCmd::Prompt(text))?; - } - } ".session" => { handler.handle(ReplCmd::StartSession(args.map(|v| v.to_string())))?; } -- cgit v1.2.3