Browse Source

refactoring: sus struct to upper camel case

main
fdai7374 2 years ago
committed by fdai7451
parent
commit
5127d6497f
  1. 2
      src/builtins/mod.rs
  2. 4
      src/builtins/sus.rs

2
src/builtins/mod.rs

@ -38,7 +38,7 @@ const BUILTINS: Lazy<Vec<(&str, Box<dyn Builtin>)>> = Lazy::new(|| {
("open", Box::new(open::Open)), ("open", Box::new(open::Open)),
("pwd", Box::new(pwd::Pwd)), ("pwd", Box::new(pwd::Pwd)),
("segfault", Box::new(segfault::Segfault)), ("segfault", Box::new(segfault::Segfault)),
("sus",Box::new(sus::sus)),
("sus",Box::new(sus::Sus)),
] ]
}); });

4
src/builtins/sus.rs

@ -2,9 +2,9 @@ use crate::error::ShellError;
use crate::builtins::{Builtin, BuiltinConfig}; use crate::builtins::{Builtin, BuiltinConfig};
pub struct sus;
pub struct Sus;
impl Builtin for sus {
impl Builtin for Sus {
fn execute(&mut self, _: &mut BuiltinConfig, _: Vec<String>) -> Result<(), ShellError> { fn execute(&mut self, _: &mut BuiltinConfig, _: Vec<String>) -> Result<(), ShellError> {
println!(" println!("

Loading…
Cancel
Save