You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
distant/src/subcommand/session.rs

15 lines
345 B
Rust

use crate::{
opt::{CommonOpt, SessionSubcommand},
utils::Session,
};
use tokio::io;
pub fn run(cmd: SessionSubcommand, _opt: CommonOpt) -> Result<(), io::Error> {
let rt = tokio::runtime::Runtime::new()?;
rt.block_on(async {
match cmd {
SessionSubcommand::Clear => Session::clear().await,
}
})
}