diff --git a/src/main.rs b/src/main.rs index 62d084d9..7e017e9f 100644 --- a/src/main.rs +++ b/src/main.rs @@ -189,7 +189,7 @@ fn run() -> Result<(), Error> { &mut terminal, )); report.push_result(execute( - |terminal| unix::run_fisherman(&base_dirs, terminal, opt.dry_run), + |terminal| unix::run_fisher(&base_dirs, terminal, opt.dry_run), &mut terminal, )); report.push_result(execute( diff --git a/src/unix.rs b/src/unix.rs index 78346029..c86f5158 100644 --- a/src/unix.rs +++ b/src/unix.rs @@ -25,13 +25,18 @@ pub fn run_zplug(base_dirs: &BaseDirs, terminal: &mut Terminal, dry_run: bool) - None } -pub fn run_fisherman(base_dirs: &BaseDirs, terminal: &mut Terminal, dry_run: bool) -> Option<(&'static str, bool)> { +pub fn run_fisher(base_dirs: &BaseDirs, terminal: &mut Terminal, dry_run: bool) -> Option<(&'static str, bool)> { if let Some(fish) = which("fish") { if base_dirs.home_dir().join(".config/fish/functions/fisher.fish").exists() { - terminal.print_separator("fisherman"); + terminal.print_separator("fisher"); let success = || -> Result<(), Error> { - Executor::new(fish, dry_run) + Executor::new(&fish, dry_run) + .args(&["-c", "fisher self-update"]) + .spawn()? + .wait()? + .check()?; + Executor::new(&fish, dry_run) .args(&["-c", "fisher"]) .spawn()? .wait()? @@ -39,7 +44,7 @@ pub fn run_fisherman(base_dirs: &BaseDirs, terminal: &mut Terminal, dry_run: boo Ok(()) }().is_ok(); - return Some(("fisherman", success)); + return Some(("fisher", success)); } }