style: make rustfmt compliant
This commit is contained in:
@@ -3,9 +3,9 @@ use crate::executor::{CommandExt, RunType};
|
|||||||
use crate::terminal::print_separator;
|
use crate::terminal::print_separator;
|
||||||
use crate::utils::{require, which};
|
use crate::utils::{require, which};
|
||||||
use directories::BaseDirs;
|
use directories::BaseDirs;
|
||||||
|
use std::env;
|
||||||
use std::path::Path;
|
use std::path::Path;
|
||||||
use std::process::Command;
|
use std::process::Command;
|
||||||
use std::env;
|
|
||||||
|
|
||||||
fn zplug_exists(base_dirs: &BaseDirs) -> bool {
|
fn zplug_exists(base_dirs: &BaseDirs) -> bool {
|
||||||
let home_exists = match env::var("ZPLUG_HOME") {
|
let home_exists = match env::var("ZPLUG_HOME") {
|
||||||
@@ -36,10 +36,7 @@ pub fn run_zplug(base_dirs: &BaseDirs, run_type: RunType) -> Option<(&'static st
|
|||||||
let success = || -> Result<(), Error> {
|
let success = || -> Result<(), Error> {
|
||||||
let zshrc = get_zshrc(base_dirs).map_err(|_| Error::from(SkipStep))?;
|
let zshrc = get_zshrc(base_dirs).map_err(|_| Error::from(SkipStep))?;
|
||||||
let cmd = format!("source {} && zplug update", zshrc);
|
let cmd = format!("source {} && zplug update", zshrc);
|
||||||
run_type
|
run_type.execute(zsh).args(&["-c", cmd.as_str()]).check_run()?;
|
||||||
.execute(zsh)
|
|
||||||
.args(&["-c", cmd.as_str()])
|
|
||||||
.check_run()?;
|
|
||||||
Ok(())
|
Ok(())
|
||||||
}()
|
}()
|
||||||
.is_ok();
|
.is_ok();
|
||||||
|
|||||||
Reference in New Issue
Block a user