Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add config serve_addr & env $SERVE_ADDR for specifying serve addr #839

Merged
merged 2 commits into from
Sep 5, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
clippy
  • Loading branch information
sigoden committed Sep 5, 2024
commit f8d6cdda71f32f1389a79dfd53693d2ef5d0245d
2 changes: 1 addition & 1 deletion src/repl/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ impl Repl {
None => println!("Usage: .prompt <text>..."),
},
".role" => match args {
Some(args) => match args.split_once(|c| c == '\n' || c == ' ') {
Some(args) => match args.split_once(['\n', ' ']) {
Some((name, text)) => {
let role = self.config.read().retrieve_role(name.trim())?;
let input = Input::from_str(&self.config, text.trim(), Some(role));
Expand Down