mirror of
https://github.com/pimalaya/himalaya.git
synced 2026-06-16 20:57:53 +08:00
1e448e56eb
In order to reduce our dependencies, we are replacing the dependencies that use console_rs with those that use crossterm. This commit will completely replace dialoguer with inquire. Signed-off-by: Perma Alesheikh <me@prma.dev>
17 lines
433 B
Rust
17 lines
433 B
Rust
use color_eyre::Result;
|
|
use email::sendmail::config::SendmailConfig;
|
|
use inquire::Text;
|
|
|
|
use crate::backend::config::BackendConfig;
|
|
|
|
pub(crate) fn configure() -> Result<BackendConfig> {
|
|
let config = SendmailConfig {
|
|
cmd: Text::new("Sendmail-compatible shell command to send emails")
|
|
.with_default("/usr/bin/msmtp")
|
|
.prompt()?
|
|
.into(),
|
|
};
|
|
|
|
Ok(BackendConfig::Sendmail(config))
|
|
}
|