mirror of
https://github.com/notohh/rustlings.git
synced 2024-12-18 06:58:10 -05:00
Making code prettier :P
This commit is contained in:
parent
74388d4bf4
commit
0f71a150ff
2 changed files with 2 additions and 5 deletions
|
@ -71,9 +71,7 @@ fn main() -> Result<()> {
|
||||||
}
|
}
|
||||||
|
|
||||||
match args.command {
|
match args.command {
|
||||||
Some(Subcommands::Init) => {
|
Some(Subcommands::Init) => return init::init().context("Initialization failed"),
|
||||||
return init::init().context("Initialization failed");
|
|
||||||
}
|
|
||||||
Some(Subcommands::Dev(dev_command)) => return dev_command.run(),
|
Some(Subcommands::Dev(dev_command)) => return dev_command.run(),
|
||||||
_ => (),
|
_ => (),
|
||||||
}
|
}
|
||||||
|
|
|
@ -153,8 +153,7 @@ pub fn clear_terminal(stdout: &mut StdoutLock) -> io::Result<()> {
|
||||||
pub fn press_enter_prompt(stdout: &mut StdoutLock) -> io::Result<()> {
|
pub fn press_enter_prompt(stdout: &mut StdoutLock) -> io::Result<()> {
|
||||||
stdout.flush()?;
|
stdout.flush()?;
|
||||||
io::stdin().lock().read_until(b'\n', &mut Vec::new())?;
|
io::stdin().lock().read_until(b'\n', &mut Vec::new())?;
|
||||||
stdout.write_all(b"\n")?;
|
stdout.write_all(b"\n")
|
||||||
Ok(())
|
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn terminal_file_link<'a>(
|
pub fn terminal_file_link<'a>(
|
||||||
|
|
Loading…
Reference in a new issue