aboutsummaryrefslogtreecommitdiffhomepage
path: root/crates/shirabe/src/command/home_command.rs
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2026-05-20 08:33:49 +0900
committernsfisis <nsfisis@gmail.com>2026-05-20 08:33:57 +0900
commitf31b101ce1e921a026ba234b1f0a83b0392bc118 (patch)
treeb7ac2aa84d71ebd162cc21aeab0240e7e0544988 /crates/shirabe/src/command/home_command.rs
parent5e31fa33c3b5cf726a57a063b8e7a070869250fe (diff)
downloadphp-shirabe-f31b101ce1e921a026ba234b1f0a83b0392bc118.tar.gz
php-shirabe-f31b101ce1e921a026ba234b1f0a83b0392bc118.tar.zst
php-shirabe-f31b101ce1e921a026ba234b1f0a83b0392bc118.zip
fix(compile): fix all remaining compile errors
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Diffstat (limited to 'crates/shirabe/src/command/home_command.rs')
-rw-r--r--crates/shirabe/src/command/home_command.rs17
1 files changed, 10 insertions, 7 deletions
diff --git a/crates/shirabe/src/command/home_command.rs b/crates/shirabe/src/command/home_command.rs
index 4f6fab3..cd13962 100644
--- a/crates/shirabe/src/command/home_command.rs
+++ b/crates/shirabe/src/command/home_command.rs
@@ -73,7 +73,9 @@ impl HomeCommand {
_output: &dyn OutputInterface,
) -> Result<i64> {
let repos = self.initialize_repos()?;
- let io = self.get_io();
+ // TODO(phase-b): clone_box to release self borrow held by get_io.
+ let io_box = self.get_io().clone_box();
+ let io: &dyn IOInterface = io_box.as_ref();
let mut return_code: i64 = 0;
let packages: Vec<String> = input
@@ -178,23 +180,23 @@ impl HomeCommand {
if Platform::is_windows() {
let _ = process.execute(
PhpMixed::from(vec!["start", "\"web\"", "explorer", url]),
- None,
- None,
+ (),
+ (),
);
return;
}
let linux = process
- .execute(PhpMixed::from(vec!["which", "xdg-open"]), None, None)
+ .execute(PhpMixed::from(vec!["which", "xdg-open"]), (), ())
.unwrap_or(1);
let osx = process
- .execute(PhpMixed::from(vec!["which", "open"]), None, None)
+ .execute(PhpMixed::from(vec!["which", "open"]), (), ())
.unwrap_or(1);
if linux == 0 {
- let _ = process.execute(PhpMixed::from(vec!["xdg-open", url]), None, None);
+ let _ = process.execute(PhpMixed::from(vec!["xdg-open", url]), (), ());
} else if osx == 0 {
- let _ = process.execute(PhpMixed::from(vec!["open", url]), None, None);
+ let _ = process.execute(PhpMixed::from(vec!["open", url]), (), ());
} else {
self.get_io().write_error(&format!(
"No suitable browser opening command found, open yourself: {}",
@@ -216,6 +218,7 @@ impl HomeCommand {
}
RepositoryFactory::default_repos_with_default_manager(self.get_io())
+ .map(|m| m.into_iter().map(|(_, v)| v).collect())
}
}