xref: /DragonOS/user/apps/user-manage/src/cmd/passwd.rs (revision 59a6bcf6aee15a11a16431bdf875905c5ecf9157)
1 use crate::{
2     check::check::PasswdCheck, error::error::ExitStatus, executor::executor::PasswdExecutor,
3     parser::parser::PasswdParser,
4 };
5 use std::process::exit;
6 
7 #[path = "../check/mod.rs"]
8 mod check;
9 #[path = "../error/mod.rs"]
10 mod error;
11 #[path = "../executor/mod.rs"]
12 mod executor;
13 #[path = "../parser/mod.rs"]
14 mod parser;
15 
16 #[allow(dead_code)]
17 fn main() {
18     let args = std::env::args().collect::<Vec<_>>();
19 
20     let cmd = PasswdParser::parse(args);
21     let info = PasswdCheck::check(cmd);
22     PasswdExecutor::execute(info);
23 
24     exit(ExitStatus::Success as i32);
25 }
26