diff --git a/src/config.rs b/src/config.rs index 97fcfe65..ddafabe3 100644 --- a/src/config.rs +++ b/src/config.rs @@ -23,6 +23,7 @@ lazy_static! { m.insert("emacs", Step::Emacs); m.insert("gem", Step::Gem); m.insert("sdkman", Step::Sdkman); + m.insert("remotes", Step::Remotes); #[cfg(windows)] m.insert("powershell", Step::Powershell); @@ -46,6 +47,8 @@ pub enum Step { Gem, /// Don't upgrade SDKMAN! and its packages Sdkman, + /// Don't run remote Togprades + Remotes, #[cfg(windows)] /// Don't update Powershell modules diff --git a/src/main.rs b/src/main.rs index 9a25011c..e9139dc4 100644 --- a/src/main.rs +++ b/src/main.rs @@ -132,13 +132,15 @@ fn run() -> Result<(), Error> { execute(&mut report, "WSL", || windows::run_wsl_topgrade(run_type), true)?; if let Some(topgrades) = config.remote_topgrades() { - for remote_topgrade in topgrades { - execute( - &mut report, - remote_topgrade, - || generic::run_remote_topgrade(run_type, remote_topgrade, config.run_in_tmux()), - config.no_retry(), - )?; + if config.should_run(Step::Remotes) { + for remote_topgrade in topgrades { + execute( + &mut report, + remote_topgrade, + || generic::run_remote_topgrade(run_type, remote_topgrade, config.run_in_tmux()), + config.no_retry(), + )?; + } } }