Browse Source

refactoring: sort builtins in mod.rs and dependencies in Cargo.toml

main
fdai7374 2 years ago
committed by fdai7451
parent
commit
0dcba36da1
  1. 3
      Cargo.toml
  2. 6
      src/builtins/mod.rs

3
Cargo.toml

@ -16,6 +16,7 @@ rustyline = "10.1"
rustyline-derive = "0.7"
shlex = "1.1"
sysinfo = "0.27"
system_shutdown = "4.0.1"
uname = "0.1"
whoami = "1.3"
system_shutdown = "4.0.1"

6
src/builtins/mod.rs

@ -7,13 +7,13 @@ mod change_prompt;
mod exit;
mod fetch;
mod help;
mod logout;
mod ls;
mod open;
mod pwd;
mod quote;
mod segfault;
mod sus;
mod logout;
pub struct BuiltinConfig {
pub prompt_style: PromptStyle,
@ -38,13 +38,13 @@ const BUILTINS: Lazy<Vec<(&str, Box<dyn Builtin>)>> = Lazy::new(|| {
("exit", Box::new(exit::Exit)),
("fetch", Box::new(fetch::Fetch)),
("help", Box::new(help::Help)),
("logout", Box::new(logout::Logout)),
("ls", Box::new(ls::Ls)),
("open", Box::new(open::Open)),
("pwd", Box::new(pwd::Pwd)),
("quote", Box::new(quote::Quote)),
("segfault", Box::new(segfault::Segfault)),
("sus", Box::new(sus::Sus)),
("quote", Box::new(quote::Quote)),
("logout", Box::new(logout::Logout)),
]
});

Loading…
Cancel
Save