chore: sync mailcore v0.1.0-beta.1

This commit is contained in:
Eugen Kaparulin
2026-04-17 09:05:47 +03:00
parent 2a4f740cbd
commit 90c8571d26
19 changed files with 4191 additions and 0 deletions

View File

@@ -0,0 +1,18 @@
use mailcore::dns::discover_mail_server;
#[tokio::main]
async fn main() {
let email = std::env::args().nth(1).expect("Usage: test_dns <email>");
println!("Discovering server for: {}", email);
match discover_mail_server(&email).await {
Ok(config) => {
println!("✓ IMAP: {}:{}", config.imap_host, config.imap_port);
println!("✓ SMTP: {}:{}", config.smtp_host, config.smtp_port);
}
Err(e) => {
eprintln!("✗ Error: {}", e);
}
}
}